Missing Type Definitions on the SAmple Schema Script
Hi Gurus,
The following is the script taken from Oracle 9i Sample schemas page. Here the scripts for some types ORDSYS.ORDImage, ORDSYS.ORDImageSignature,ORDSYS.ORDVideo,ORDSYS.ORDAudio,ORDSYS.ORDDoc are not given.
Can you help me in getting those.
CREATE TABLE online_media
( product_id NUMBER(6)
, product_photo ORDSYS.ORDImage
, product_photo_signature ORDSYS.ORDImageSignature
, product_thumbnail ORDSYS.ORDImage
, product_video ORDSYS.ORDVideo
, product_audio ORDSYS.ORDAudio
, product_text CLOB
, product_testimonials ORDSYS.ORDDoc
) ;
Does your database have Oracle Intermedia installed?
The other thing to check is whether your DBA has revoked execute on those objects from public. A couple of them served as vectors for DoS attacks against the database,
Cheers, APC
Blog : http://radiofreetooting.blogspot.com/
Similar Messages
-
Hi I am new to sqlOracle
I was trying to follow some Oracle tutorial,but i needed to install the sample schemas (OE-order entry) first
http://www.oracle.com/technology/obe/obe1013jdev/common/OBEConnection.htm
1. First i download the sample_schema_scripts.zip and extracted into the folder
c:\schema that i created
2. I start database from my database OracleEX10g
3. go to the C:\schema that have the sql script (oe8_main.sql)
4.use sqlplus
5. login as system and put the password
6. run the scripts oe8_main.sql with no problems
7. it asked me for " specify password for oe8 as parameter 1:
and i need to enter value for 1: which is i dont know
8. i need to fil this value til parameter 6
9. so i typed the value &1 for parameter 1 and &2 for parameter 2...til parameter 6
10. it showned error:
ERROR at line 1:
ora-00988 : missing or invalid passwords(s)
and user or role 'OE8" does not exist and
ask me to enter value for database_name: which i dont know
11. anyone can help to solve the problem and how can i know what are the passwords for 6 parameters
12. Do i need to create my new user because i used system as a user
13. this is the content of oe8_main.sql file attached:
SET ECHO OFF
PROMPT
PROMPT specify password for oe8 as parameter 1:
DEFINE pass = &1
PROMPT
PROMPT specify default tablespeace for oe8 as parameter 2:
DEFINE tbs = &2
PROMPT
PROMPT specify temporary tablespace for oe8 as parameter 3:
DEFINE ttbs = &3
PROMPT
PROMPT specify password for HR as parameter 4:
DEFINE passhr = &4
PROMPT
PROMPT specify password for SYS as parameter 5:
DEFINE pass_sys = &5
PROMPT
PROMPT specify path for log files as parameter 6:
DEFINE log_path = &6
PROMPT
-- The first dot in the spool command below is
-- the SQL*Plus concatenation character
DEFINE spool_file = &log_path.oe8_main.log
SPOOL &spool_file
-- Dropping the user with all its objects
DROP USER oe8 CASCADE;
REM =======================================================
REM create user
REM
REM The user is assigned tablespaces and quota in separate
REM ALTER USER statements so that the CREATE USER statement
REM will succeed even if the demo and temp tablespaces do
REM not exist.
REM =======================================================
CREATE USER oe8 IDENTIFIED BY &pass;
ALTER USER oe8 DEFAULT TABLESPACE &tbs QUOTA UNLIMITED ON &tbs;
ALTER USER oe8 TEMPORARY TABLESPACE &ttbs;
GRANT CONNECT TO oe8;
GRANT RESOURCE TO oe8;
GRANT CREATE MATERIALIZED VIEW TO oe8;
GRANT QUERY REWRITE TO oe8;
REM =======================================================
REM grants from sys schema
REM =======================================================
rem KM: 01Aug02 - remove "AS SYSDBA" clause - NOT needed FOR GRANT
CONNECT sys/&pass_sys&&database_name
GRANT execute ON sys.dbms_stats TO oe8;
REM =======================================================
REM grants from hr8 schema
REM =======================================================
CONNECT hr8/&passhr&&database_name;
GRANT REFERENCES, SELECT ON employees TO oe8;
GRANT REFERENCES, SELECT ON countries TO oe8;
GRANT REFERENCES, SELECT ON locations TO oe8;
GRANT SELECT ON jobs TO oe8;
GRANT SELECT ON job_history TO oe8;
GRANT SELECT ON departments TO oe8;
REM =======================================================
REM create oe8 schema (order entry)
REM =======================================================
CONNECT oe8/&pass&&database_name
ALTER SESSION SET NLS_LANGUAGE=American;
ALTER SESSION SET NLS_TERRITORY=America;
@@oe8_cre
@@oe8_p_pi
@@oe8_p_pd
@@oe8_p_whs
@@oe8_p_cus
@@oe8_p_ord
@@oe8_p_itm
@@oe8_p_inv
@@oe8_views
@@oe8_comnt
@@oe8_idx
@@oe8_analz
spool offHi,
HR sample schema already comes with Oracle XE, so you don't need to re-install it. Anyways ...
C:\>sqlplus / as sysdba
SQL*Plus: Release 10.2.0.1.0 - Production on Sun Jun 22 12:58:20 2008
Copyright (c) 1982, 2005, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Express Edition Release 10.2.0.1.0 - Production
SYS@XE> @C:\oraclexe\app\oracle\product\10.2.0\server\demo\schema\human_resources\hr_main.sql;
specify password for HR as parameter 1:
Enter value for 1: HR -- put here some password
specify default tablespeace for HR as parameter 2:
Enter value for 2: USERS
specify temporary tablespace for HR as parameter 3:
Enter value for 3: TEMP
specify password for SYS as parameter 4:
Enter value for 4: MANAGER -- password that you defined at Oracle XE installation
specify log path as parameter 5:
Enter value for 5: C:\
User dropped.
old 1: CREATE USER hr IDENTIFIED BY &pass
new 1: CREATE USER hr IDENTIFIED BY hr
User created.
old 1: ALTER USER hr DEFAULT TABLESPACE &tbs
new 1: ALTER USER hr DEFAULT TABLESPACE users
old 2: QUOTA UNLIMITED ON &tbs
new 2: QUOTA UNLIMITED ON users
User altered.
old 1: ALTER USER hr TEMPORARY TABLESPACE &ttbs
new 1: ALTER USER hr TEMPORARY TABLESPACE temp
User altered.
Grant succeeded.
Grant succeeded.
Connected.
Grant succeeded.
Connected.
Session altered.
Session altered.
****** Creating REGIONS table ....
Table created.
Index created.
Table altered.
****** Creating COUNTRIES table ....
Table created.
Table altered.
****** Creating LOCATIONS table ....
Table created.
Index created.
Table altered.
Sequence created.
****** Creating DEPARTMENTS table ....
Table created.
Index created.
Table altered.
Sequence created.
****** Creating JOBS table ....
Table created.
Index created.
Table altered.
****** Creating EMPLOYEES table ....
Table created.
Index created.
Table altered.
Table altered.
Sequence created.
****** Creating JOB_HISTORY table ....
Table created.
Index created.
Table altered.
****** Creating EMP_DETAILS_VIEW view ...
View created.
Commit complete.
Session altered.
****** Populating REGIONS table ....
1 row created.
1 row created.
1 row created.
1 row created.
****** Populating COUNTIRES table ....
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
****** Populating LOCATIONS table ....
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
****** Populating DEPARTMENTS table ....
Table altered.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
****** Populating JOBS table ....
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
****** Populating EMPLOYEES table ....
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
****** Populating JOB_HISTORY table ....
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
1 row created.
Table altered.
Commit complete.
Index created.
Index created.
Index created.
Index created.
Index created.
Index created.
Index created.
Index created.
Index created.
Index created.
Index created.
Commit complete.
Procedure created.
Trigger created.
Trigger altered.
Procedure created.
Trigger created.
Commit complete.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Comment created.
Commit complete.
PL/SQL procedure successfully completed.Cheers
Legatti -
I have installed 10g application server and jdeveloper - but cannot find any of the scripts to create the sample schema. From searching the OTN forums it seams that the onl way of obtaing these scripts is to install the database or companion disk and run from the demo folder.
This seems a bit over the top - i had intended to use the infrastructure database, (my system dosn't have enough resources to install a seperate database), can any helpful person email the scripts, perhaps someone from oracle might be able to make this easier there seems to be a fair bit of interest in this on the forums.
Many thanks Terry BennettHi Terry,
When you installed Oracle 10g, the demo tables should have been installed under the scott schema. Try select * from scott.emp and see if you get any results. Incase you are looking for the script for the demo tables, its in $ORACLE_HOME/rdbms/admin/utlsampl.sql (in my case its in C:\oracle\product\10.1.0\Db_1\RDBMS\ADMIN).
Hope that helps.
-Raj -
What are the sample schemas(like scott,hr) in oracle 12c?
Hi,
I have just downloaded and installed the oracle 12c on my desktop(Hurray!), but i don't see any of the sample schemas like scott and hr to play with. Do we have anything like those schemas in 12c?
Thanks,
sgI have just downloaded and installed the oracle 12c on my desktop(Hurray!), but i don't see any of the sample schemas like scott and hr to play with. Do we have anything like those schemas in 12c?
Yes - but they would be in a PDB if you installed the sample schemas; you won't find them in the CDB.
If, like many people new to 12c, you did a default install for a database named ORCL and then connect to ORCL you are connecting to the CDB; that is, the root container. You won't find any sample schema there.
If you installed the sample schemas then the install process would have created one PDB name PDBORCL (by default) and that PDB would contain the sample schemas.
Then the next thing users typically do is connect as sysdba and do a STARTUP and then find they can't connect to PDBORCL. Surprise! The PDBs are NOT opened by default; you need to open them manually when you startup the DB or create an AFTER STARTUP trigger that opens the ones you want.
Review chapters 17 and 18 of the Database Concepts doc
http://docs.oracle.com/cd/E16655_01/server.121/e17633/cdbovrvw.htm -
Hi All!
Sample schemas (HR, OE, PM, QS, and SH) scripts are missing from 10g (10.2.0.1.0) on Win XP Pro(32-bit)
I have checked $ORACLE_HOME/demo/schema directory: There is subdirectory for each schema.
The scripts are not there or only some of them scripts are installed.
The list of correct scripts is hear:
http://download.oracle.com/docs/cd/B19306_01/server.102/b14198/scripts.htm#sthref77
Where to get scripts to rebuild sample schemas manually?
Thank youWelcome to the forums !
The scripts should be available in the companion directory of the CD
http://download.oracle.com/docs/cd/B19306_01/server.102/b14198/installation.htm#I4367
HTH
Srini -
Oracle 11gR2 HR sample schema scripts not found
after installing oracle 11gR2 on Linux (software + create new database without sample schema); I want install sample HR schema now but the problem is
required scripts to create HR schema not found in 'demo' folder :
[oracle@host schema]$ pwd
/home/oracle/app/oracle/product/11.2.0/db_1/demo/schema
[oracle@host schema]$ ls -l
drwxr-xr-x 2 oracle dba 4096 Sep 4 07:41 bus_intelligence
-rw-r--r-- 1 oracle dba 2322 Apr 3 2009 drop_sch.sql
drwxr-xr-x 2 oracle dba 4096 Sep 9 12:59 human_resources
drwxr-xr-x 2 oracle dba 4096 Sep 4 07:49 log
-rw-r--r-- 1 oracle dba 1769 Sep 4 07:53 mk_dir.sql
-rw-r--r-- 1 oracle dba 1769 Sep 4 07:53 mk_dir.sql.ouibak
-rw-r--r-- 1 oracle dba 1600 Aug 16 2006 mk_dir.sql.sbs
-rw-r--r-- 1 oracle dba 27373 Jun 30 2007 mkplug.sql
drwxr-xr-x 3 oracle dba 4096 Sep 4 07:49 order_entry
drwxr-xr-x 2 oracle dba 4096 Sep 4 07:41 sales_history
-rw-r--r-- 1 oracle dba 15246 May 10 2005 sted_mkplug.sql.dbl
[oracle@host1 schema]$ ls human_resources/
hr_code.sql
what's wrong ??Pl post exact OS version. When installing the software, did you download and unzip all 7 DVDs or just the first 2 ? If just the first 2, you will need to download the examples separately
http://www.oracle.com/technetwork/database/enterprise-edition/downloads/112010-linuxsoft-085393.html
or
http://www.oracle.com/technetwork/database/enterprise-edition/downloads/112010-linx8664soft-100572.html
then follow instructions in the Samples Guide - http://docs.oracle.com/cd/E11882_01/server.112/e10831/toc.htm
HTH
Srini -
Where is HR Sample Schema Script for APEX 2.2
Just installed APEX 2.2 and am reviewing the 2-day developers guide. In there they give many examples based on an HR sample schema which they say can be downloaded from http://www.oracle.com/technology/products/database/application_express/code/hr_sample_schema.sql
I'm finding this address invalid. Does anyone know the right url for the script or can someone supply it to me?Hi skondolf1,
I don't know where that specific script is now, but you can also get the HR samle schema here: http://www.oracle.com/technology/obe/obe1013jdev/common/files/sample_schema_scripts9i10g.zip
Regards Pete -
10g Sample Schema code missing
Hi...On installation of 10g db (10.1.0.2.0), the expected sample schemas are not provided.
I have tried multiple installs in order to try and extract the sql scripts.
e.g. hr_main.sql, oe_main.sql and bi_main.sql.
These sample schemas are not the same as the 9i sample schemas, which can be accessed in text format in existing documentation for 9i.
Does anyone know where the actual scripts can be accessed other than from installation CDs and dowloaded installation...as neither provide the necessary scripts for the sample schemas?
Thanks,
Tonyi am also having same problem.
some one will provide the right info for you but you can try this too:
SQL> ALTER USER HR IDENTIFIED BY <password> account unlock;
User altered.
SQL> connect hr/<password>@<connection string/SID>;
Connected.
SQL> desc employees;
Name Null? Type
EMPLOYEE_ID NOT NULL NUMBER(6)
FIRST_NAME VARCHAR2(20)
LAST_NAME NOT NULL VARCHAR2(25)
EMAIL NOT NULL VARCHAR2(25)
PHONE_NUMBER VARCHAR2(20)
HIRE_DATE NOT NULL DATE
JOB_ID NOT NULL VARCHAR2(10)
SALARY NUMBER(8,2)
COMMISSION_PCT NUMBER(2,2)
MANAGER_ID NUMBER(6)
DEPARTMENT_ID NUMBER(4)
SQL> select * from employees;
EMPLOYEE_ID FIRST_NAME LAST_NAME
EMAIL PHONE_NUMBER HIRE_DATE JOB_ID SALARY
COMMISSION_PCT MANAGER_ID DEPARTMENT_ID
198 Donald OConnell
DOCONNEL 650.507.9833 21-JUN-99 SH_CLERK 2600
124 50
199 Douglas Grant
DGRANT 650.507.9844 13-JAN-00 SH_CLERK 2600
124 50
200 Jennifer Whalen
JWHALEN 515.123.4444 17-SEP-87 AD_ASST 4400
101 10
201 Michael Hartstein
MHARTSTE 515.123.5555 17-FEB-96 MK_MAN 13000
100 20
202 Pat Fay
PFAY 603.123.6666 17-AUG-97 MK_REP 6000
201 20
203 Susan Mavris
SMAVRIS 515.123.7777 07-JUN-94 HR_REP 6500
101 40
204 Hermann Baer
HBAER 515.123.8888 07-JUN-94 PR_REP 10000
101 70
205 Shelley Higgins
SHIGGINS 515.123.8080 07-JUN-94 AC_MGR 12000
101 110
206 William Gietz
WGIETZ 515.123.8181 07-JUN-94 AC_ACCOUNT 8300
205 110
100 Steven King
SKING 515.123.4567 17-JUN-87 AD_PRES 24000
90
101 Neena Kochhar
NKOCHHAR 515.123.4568 21-SEP-89 AD_VP 17000
100 90
102 Lex De Haan
LDEHAAN 515.123.4569 13-JAN-93 AD_VP 17000
100 90
103 Alexander Hunold
AHUNOLD 590.423.4567 03-JAN-90 IT_PROG 9000
102 60
104 Bruce Ernst
BERNST 590.423.4568 21-MAY-91 IT_PROG 6000
103 60
105 David Austin
DAUSTIN 590.423.4569 25-JUN-97 IT_PROG 4800
103 60
106 Valli Pataballa
VPATABAL 590.423.4560 05-FEB-98 IT_PROG 4800
103 60
107 Diana Lorentz
DLORENTZ 590.423.5567 07-FEB-99 IT_PROG 4200
103 60
108 Nancy Greenberg
NGREENBE 515.124.4569 17-AUG-94 FI_MGR 12000
101 100
109 Daniel Faviet
DFAVIET 515.124.4169 16-AUG-94 FI_ACCOUNT 9000
108 100
110 John Chen
JCHEN 515.124.4269 28-SEP-97 FI_ACCOUNT 8200
108 100
111 Ismael Sciarra
ISCIARRA 515.124.4369 30-SEP-97 FI_ACCOUNT 7700
108 100
112 Jose Manuel Urman
JMURMAN 515.124.4469 07-MAR-98 FI_ACCOUNT 7800
108 100
113 Luis Popp
LPOPP 515.124.4567 07-DEC-99 FI_ACCOUNT 6900
108 100
114 Den Raphaely
EMPLOYEE_ID FIRST_NAME LAST_NAME
EMAIL PHONE_NUMBER HIRE_DATE JOB_ID SALARY
COMMISSION_PCT MANAGER_ID DEPARTMENT_ID
DRAPHEAL 515.127.4561 07-DEC-94 PU_MAN 11000
100 30
115 Alexander Khoo
AKHOO 515.127.4562 18-MAY-95 PU_CLERK 3100
114 30
116 Shelli Baida
SBAIDA 515.127.4563 24-DEC-97 PU_CLERK 2900
114 30
117 Sigal Tobias
STOBIAS 515.127.4564 24-JUL-97 PU_CLERK 2800
114 30
118 Guy Himuro
GHIMURO 515.127.4565 15-NOV-98 PU_CLERK 2600
114 30
119 Karen Colmenares
KCOLMENA 515.127.4566 10-AUG-99 PU_CLERK 2500
114 30
120 Matthew Weiss
MWEISS 650.123.1234 18-JUL-96 ST_MAN 8000
100 50
121 Adam Fripp
AFRIPP 650.123.2234 10-APR-97 ST_MAN 8200
100 50
122 Payam Kaufling
PKAUFLIN 650.123.3234 01-MAY-95 ST_MAN 7900
100 50
123 Shanta Vollman
SVOLLMAN 650.123.4234 10-OCT-97 ST_MAN 6500
100 50
124 Kevin Mourgos
KMOURGOS 650.123.5234 16-NOV-99 ST_MAN 5800
100 50
125 Julia Nayer
JNAYER 650.124.1214 16-JUL-97 ST_CLERK 3200
120 50
126 Irene Mikkilineni
IMIKKILI 650.124.1224 28-SEP-98 ST_CLERK 2700
120 50
127 James Landry
JLANDRY 650.124.1334 14-JAN-99 ST_CLERK 2400
120 50
128 Steven Markle
SMARKLE 650.124.1434 08-MAR-00 ST_CLERK 2200
120 50
129 Laura Bissot
LBISSOT 650.124.5234 20-AUG-97 ST_CLERK 3300
121 50
130 Mozhe Atkinson
MATKINSO 650.124.6234 30-OCT-97 ST_CLERK 2800
121 50
131 James Marlow
JAMRLOW 650.124.7234 16-FEB-97 ST_CLERK 2500
121 50
132 TJ Olson
TJOLSON 650.124.8234 10-APR-99 ST_CLERK 2100
121 50
133 Jason Mallin
JMALLIN 650.127.1934 14-JUN-96 ST_CLERK 3300
122 50
134 Michael Rogers
MROGERS 650.127.1834 26-AUG-98 ST_CLERK 2900
122 50
135 Ki Gee
KGEE 650.127.1734 12-DEC-99 ST_CLERK 2400
122 50
136 Hazel Philtanker
HPHILTAN 650.127.1634 06-FEB-00 ST_CLERK 2200
122 50
137 Renske Ladwig
RLADWIG 650.121.1234 14-JUL-95 ST_CLERK 3600
EMPLOYEE_ID FIRST_NAME LAST_NAME
EMAIL PHONE_NUMBER HIRE_DATE JOB_ID SALARY
COMMISSION_PCT MANAGER_ID DEPARTMENT_ID
123 50
138 Stephen Stiles
SSTILES 650.121.2034 26-OCT-97 ST_CLERK 3200
123 50
139 John Seo
JSEO 650.121.2019 12-FEB-98 ST_CLERK 2700
123 50
140 Joshua Patel
JPATEL 650.121.1834 06-APR-98 ST_CLERK 2500
123 50
141 Trenna Rajs
TRAJS 650.121.8009 17-OCT-95 ST_CLERK 3500
124 50
142 Curtis Davies
CDAVIES 650.121.2994 29-JAN-97 ST_CLERK 3100
124 50
143 Randall Matos
RMATOS 650.121.2874 15-MAR-98 ST_CLERK 2600
124 50
144 Peter Vargas
PVARGAS 650.121.2004 09-JUL-98 ST_CLERK 2500
124 50
145 John Russell
JRUSSEL 011.44.1344.429268 01-OCT-96 SA_MAN 14000
.4 100 80
146 Karen Partners
KPARTNER 011.44.1344.467268 05-JAN-97 SA_MAN 13500
.3 100 80
147 Alberto Errazuriz
AERRAZUR 011.44.1344.429278 10-MAR-97 SA_MAN 12000
.3 100 80
148 Gerald Cambrault
GCAMBRAU 011.44.1344.619268 15-OCT-99 SA_MAN 11000
.3 100 80
149 Eleni Zlotkey
EZLOTKEY 011.44.1344.429018 29-JAN-00 SA_MAN 10500
.2 100 80
150 Peter Tucker
PTUCKER 011.44.1344.129268 30-JAN-97 SA_REP 10000
.3 145 80
151 David Bernstein
DBERNSTE 011.44.1344.345268 24-MAR-97 SA_REP 9500
.25 145 80
152 Peter Hall
PHALL 011.44.1344.478968 20-AUG-97 SA_REP 9000
.25 145 80
153 Christopher Olsen
COLSEN 011.44.1344.498718 30-MAR-98 SA_REP 8000
.2 145 80
154 Nanette Cambrault
NCAMBRAU 011.44.1344.987668 09-DEC-98 SA_REP 7500
.2 145 80
155 Oliver Tuvault
OTUVAULT 011.44.1344.486508 23-NOV-99 SA_REP 7000
.15 145 80
156 Janette King
JKING 011.44.1345.429268 30-JAN-96 SA_REP 10000
.35 146 80
157 Patrick Sully
PSULLY 011.44.1345.929268 04-MAR-96 SA_REP 9500
.35 146 80
158 Allan McEwen
AMCEWEN 011.44.1345.829268 01-AUG-96 SA_REP 9000
.35 146 80
159 Lindsey Smith
LSMITH 011.44.1345.729268 10-MAR-97 SA_REP 8000
.3 146 80
160 Louise Doran
LDORAN 011.44.1345.629268 15-DEC-97 SA_REP 7500
.3 146 80
EMPLOYEE_ID FIRST_NAME LAST_NAME
EMAIL PHONE_NUMBER HIRE_DATE JOB_ID SALARY
COMMISSION_PCT MANAGER_ID DEPARTMENT_ID
161 Sarath Sewall
SSEWALL 011.44.1345.529268 03-NOV-98 SA_REP 7000
.25 146 80
162 Clara Vishney
CVISHNEY 011.44.1346.129268 11-NOV-97 SA_REP 10500
.25 147 80
163 Danielle Greene
DGREENE 011.44.1346.229268 19-MAR-99 SA_REP 9500
.15 147 80
164 Mattea Marvins
MMARVINS 011.44.1346.329268 24-JAN-00 SA_REP 7200
.1 147 80
165 David Lee
DLEE 011.44.1346.529268 23-FEB-00 SA_REP 6800
.1 147 80
166 Sundar Ande
SANDE 011.44.1346.629268 24-MAR-00 SA_REP 6400
.1 147 80
167 Amit Banda
ABANDA 011.44.1346.729268 21-APR-00 SA_REP 6200
.1 147 80
168 Lisa Ozer
LOZER 011.44.1343.929268 11-MAR-97 SA_REP 11500
.25 148 80
169 Harrison Bloom
HBLOOM 011.44.1343.829268 23-MAR-98 SA_REP 10000
.2 148 80
170 Tayler Fox
TFOX 011.44.1343.729268 24-JAN-98 SA_REP 9600
.2 148 80
171 William Smith
WSMITH 011.44.1343.629268 23-FEB-99 SA_REP 7400
.15 148 80
172 Elizabeth Bates
EBATES 011.44.1343.529268 24-MAR-99 SA_REP 7300
.15 148 80
173 Sundita Kumar
SKUMAR 011.44.1343.329268 21-APR-00 SA_REP 6100
.1 148 80
174 Ellen Abel
EABEL 011.44.1644.429267 11-MAY-96 SA_REP 11000
.3 149 80
175 Alyssa Hutton
AHUTTON 011.44.1644.429266 19-MAR-97 SA_REP 8800
.25 149 80
176 Jonathon Taylor
JTAYLOR 011.44.1644.429265 24-MAR-98 SA_REP 8600
.2 149 80
177 Jack Livingston
JLIVINGS 011.44.1644.429264 23-APR-98 SA_REP 8400
.2 149 80
178 Kimberely Grant
KGRANT 011.44.1644.429263 24-MAY-99 SA_REP 7000
.15 149
179 Charles Johnson
CJOHNSON 011.44.1644.429262 04-JAN-00 SA_REP 6200
.1 149 80
180 Winston Taylor
WTAYLOR 650.507.9876 24-JAN-98 SH_CLERK 3200
120 50
181 Jean Fleaur
JFLEAUR 650.507.9877 23-FEB-98 SH_CLERK 3100
120 50
182 Martha Sullivan
MSULLIVA 650.507.9878 21-JUN-99 SH_CLERK 2500
120 50
183 Girard Geoni
GGEONI 650.507.9879 03-FEB-00 SH_CLERK 2800
120 50
EMPLOYEE_ID FIRST_NAME LAST_NAME
EMAIL PHONE_NUMBER HIRE_DATE JOB_ID SALARY
COMMISSION_PCT MANAGER_ID DEPARTMENT_ID
184 Nandita Sarchand
NSARCHAN 650.509.1876 27-JAN-96 SH_CLERK 4200
121 50
185 Alexis Bull
ABULL 650.509.2876 20-FEB-97 SH_CLERK 4100
121 50
186 Julia Dellinger
JDELLING 650.509.3876 24-JUN-98 SH_CLERK 3400
121 50
187 Anthony Cabrio
ACABRIO 650.509.4876 07-FEB-99 SH_CLERK 3000
121 50
188 Kelly Chung
KCHUNG 650.505.1876 14-JUN-97 SH_CLERK 3800
122 50
189 Jennifer Dilly
JDILLY 650.505.2876 13-AUG-97 SH_CLERK 3600
122 50
190 Timothy Gates
TGATES 650.505.3876 11-JUL-98 SH_CLERK 2900
122 50
191 Randall Perkins
RPERKINS 650.505.4876 19-DEC-99 SH_CLERK 2500
122 50
192 Sarah Bell
SBELL 650.501.1876 04-FEB-96 SH_CLERK 4000
123 50
193 Britney Everett
BEVERETT 650.501.2876 03-MAR-97 SH_CLERK 3900
123 50
194 Samuel McCain
SMCCAIN 650.501.3876 01-JUL-98 SH_CLERK 3200
123 50
195 Vance Jones
VJONES 650.501.4876 17-MAR-99 SH_CLERK 2800
123 50
196 Alana Walsh
AWALSH 650.507.9811 24-APR-98 SH_CLERK 3100
124 50
197 Kevin Feeney
KFEENEY 650.507.9822 23-MAY-98 SH_CLERK 3000
124 50
107 rows selected.
SQL> you if you want to give access permission to SYS or System do:
SQL> grant select on employees to system;
Grant succeeded.
SQL> grant select on employees to sys;
Grant succeeded.
SQL> Its just worked for me.
HTH
Edited by: sayantan chakraborty on Aug 20, 2009 12:31 PM -
Missing Oracle Sample Schemas - How Download complete Files
Dear DBA's
I appreciate if someone could tell me how setup the ORACLE SAMPLE SCHEMAS, because all my demo folders in 10g and 11G
$ORACLE_HOME/demo/schema/hr or oe or any other chema there are fiesl missing,
for instnace looking at the Procedure in doc
http://download.oracle.com/docs/cd/B28359_01/server.111/b28328.pdf
it says to run "hr_main.sql" script in folder $ORACLE_HOME/demo/schema/human_resources
But I can't find any file"hr_main"
then for PM Schema it's supposed to have a file pm_main.sql !!!! I can't find .....
The same for SH (Sales History) they say to run the "sh_main.sql" but i can't find anything like "Main"
Can you please help me to compltely setup the sample schemas ?
TxsI am having the same problem.
I am running XE and the only sample schema that exists there is HR.
OE and SH...are not there
I downloaded companion CD 10 minutes ago from
http://www.oracle.com/technetwork/database/10201winsoft-095341.html
and searched through the whole companion and no
files like :
sh_main.sql
mksample
nothing!
User Steve Callan placed a data pump file on
http://www.dbasupport.com/oracle/ora11g/Installing-Oracle-Database-Sample-Schemas-using-Data-Pump.shtml
but he created it without version parameter, so people who are running data pum from older versions cannot import it.
I made a comment on the article he posted .
user13106173 pointed out a link where you can get OE and HR, but I need SH sample schema as well
So please can somebody direct me to anyplace I can get ALL THE Sample schemas -
Where to download scripts for HR sample schema
Hi,
i installed Oracle11g on linux without sample schemas.
now i want to manually install the sample schemas.
and when i checked the folders under "../human_resources"
i am not able to view the scripts to install HR schema.
i tried a lot of google search but i am not able to find and download the scripts needed to create HR objects.
Can someone guide me where i can find scripts that i can download and install all the sample schema objects
Thanks,
Philip.It's part of the Companion install
-
I am working on a map where there are two nodes of type Child in the source schema. These nodes do not repeat, they are predefined Ex
<TopLevel>
<MainChild>
<FirstName>Tom</FirstName>
<LastName>Harry</LastName>
<Address>London</Address>
</MainChild>
<BillingChild>
<FirstName>John</FirstName>
<LastName>Marry</LastName>
<Address>Paris</Address>
</BillingChild>
</TopLevel>
This message is to be mapped to a destination schemas which has a repeating <Child> node. Ex
<TopLevel>
<Child min=0 max=unbounded>
<FirstName></FirstName>
<LastName></LastName>
<Address></Address>
</Child>
</TopLevel>
How to map from the above source schema to the destination schema.
If any one has any idea how implement this pls share you approach.Hello Rishi,
To achieve this, you have to use the Looping functoid. where First link the Nodes of source to Destination via Looping functoid and then map individual links. The Looping functoid will repeat your Destination node as many Source inputs.
I have tried your scenario. Please check the below image of mapping,
Atul Toke -
Script or direction to add sample schema tables to database
I created a Database at installation time of oracle 10g exempting the sample schema tables to be added later. Iam ready to add it now and I can not find the way. Please, how?
Hi srideeq,
The sample schema you can find in
ORACLE_HOME/demo/schema
Cheera,
Kamalesh JK -
I have installed 10g xe. I am self training using the oracle press book "Oracle Database 10g A Beginner's Guide." However, the book indicates that the customer table, mentioned in chapter 2 is provided as part of the sample schema in 10g. But the only schema I have is HR. Is there a place where I can download and import the schemas mentioned in the book? Or must I install enterprise edition in order to work with them? Thanks to any that can assist.
The Order Entry (OE) schema builds on the purely relational Human Relations (HR) schema with some object-relational and object-oriented features. The OE schema contains seven tables: Customers, Product_Descriptions, Product_Information, Order_Items, Orders, Inventories, and Warehouses. The OE schema has links into the HR schema and PM schema. This schema also has synonyms defined on HR objects to make access transparent to users.
rem
rem Header: oe_cre.sql 09-jan-01
rem
rem Copyright (c) 2001, 2002, Oracle Corporation. All rights reserved.
rem
rem Owner : ahunold
rem
rem NAME
rem oe_cre.sql - create OE Common Schema
rem
rem DESCRIPTON
rem Creates database objects. The script assumes that the HR schema
rem is present.
rem
rem NOTES
rem The OIDs assigned for the object types are used to
rem simplify the setup of Replication demos and are not needed
rem in most unreplicated environments.
rem
rem MODIFIED (MM/DD/YY)
rem hyeh 08/29/02 - hyeh_mv_comschema_to_rdbms
rem ahunold 09/17/01 - FK in PRODUCT_DESCRIPTIONS
rem ahunold 04/25/01 - OID
rem ahunold 03/02/01 - eliminating DROP SEQUENCE
rem ahunold 01/30/01 - OE script headers
rem ahunold 01/24/01 - Eliminate extra lines from last merge
rem ahunold 01/05/01 - promo_id
rem ahunold 01/05/01 - NN constraints in product_descriptions
rem ahunold 01/09/01 - checkin ADE
PROMPT
PROMPT specify Sample Schema version as parameter 1:
DEFINE vrs = &1
PROMPT
-- ======================================================================
-- Type definitions
-- ======================================================================
CREATE TYPE cust_address_typ
OID '82A4AF6A4CD1656DE034080020E0EE3D'
AS OBJECT
( street_address VARCHAR2(40)
, postal_code VARCHAR2(10)
, city VARCHAR2(30)
, state_province VARCHAR2(10)
, country_id CHAR(2)
REM ===========================================================================
REM Create phone_list_typ varray to be varray column in customers table.
REM ===========================================================================
CREATE TYPE phone_list_typ
OID '82A4AF6A4CD2656DE034080020E0EE3D'
AS VARRAY(5) OF VARCHAR2(25);
REM ===========================================================================
REM Create customers table.
REM The cust_geo_location column will become MDSYS.SDO_GEOMETRY (spatial)
REM datatype when appropriate scripts and data are available.
REM ===========================================================================
DEFINE vscript = ?/demo/schema/order_entry/ccus_&vrs
@&vscript
CREATE UNIQUE INDEX customers_pk
ON customers (customer_id) ;
REM Both table and indexes are analyzed using the oe_analz.sql script.
ALTER TABLE customers
ADD ( CONSTRAINT customers_pk
PRIMARY KEY (customer_id)
REM ===========================================================================
REM Create warehouses table;
REM includes spatial data column wh_geo_location and
REM XML type warehouse_spec (was bug b41)
REM ===========================================================================
DEFINE vscript = ?/demo/schema/order_entry/cwhs_&vrs
@&vscript
CREATE UNIQUE INDEX warehouses_pk
ON warehouses (warehouse_id) ;
ALTER TABLE warehouses
ADD (CONSTRAINT warehouses_pk PRIMARY KEY (warehouse_id)
REM ===========================================================================
REM Create table order_items.
REM ===========================================================================
CREATE TABLE order_items
( order_id NUMBER(12)
, line_item_id NUMBER(3) NOT NULL
, product_id NUMBER(6) NOT NULL
, unit_price NUMBER(8,2)
, quantity NUMBER(8)
CREATE UNIQUE INDEX order_items_pk
ON order_items (order_id, line_item_id) ;
CREATE UNIQUE INDEX order_items_uk
ON order_items (order_id, product_id) ;
ALTER TABLE order_items
ADD ( CONSTRAINT order_items_pk PRIMARY KEY (order_id, line_item_id)
CREATE OR REPLACE TRIGGER insert_ord_line
BEFORE INSERT ON order_items
FOR EACH ROW
DECLARE
new_line number;
BEGIN
SELECT (NVL(MAX(line_item_id),0)+1) INTO new_line
FROM order_items
WHERE order_id = :new.order_id;
:new.line_item_id := new_line;
END;
REM ===========================================================================
REM Create table orders, which includes a TIMESTAMP column and a check
REM constraint.
REM ===========================================================================
DEFINE vscript = ?/demo/schema/order_entry/cord_&vrs
@&vscript
CREATE UNIQUE INDEX order_pk
ON orders (order_id) ;
ALTER TABLE orders
ADD ( CONSTRAINT order_pk
PRIMARY KEY (order_id)
REM ===========================================================================
REM Create inventories table, which contains a concatenated primary key.
REM ===========================================================================
CREATE TABLE inventories
( product_id NUMBER(6)
, warehouse_id NUMBER(3) CONSTRAINT inventory_warehouse_id_nn NOT NULL
, quantity_on_hand NUMBER(8)
CONSTRAINT inventory_qoh_nn NOT NULL
, CONSTRAINT inventory_pk PRIMARY KEY (product_id, warehouse_id)
REM ===========================================================================
REM Create table product_information, which contains an INTERVAL datatype and
REM a CHECK ... IN constraint.
REM ===========================================================================
CREATE TABLE product_information
( product_id NUMBER(6)
, product_name VARCHAR2(50)
, product_description VARCHAR2(2000)
, category_id NUMBER(2)
, weight_class NUMBER(1)
, warranty_period INTERVAL YEAR TO MONTH
, supplier_id NUMBER(6)
, product_status VARCHAR2(20)
, list_price NUMBER(8,2)
, min_price NUMBER(8,2)
, catalog_url VARCHAR2(50)
, CONSTRAINT product_status_lov
CHECK (product_status in ('orderable'
,'planned'
,'under development'
,'obsolete')
ALTER TABLE product_information
ADD ( CONSTRAINT product_information_pk PRIMARY KEY (product_id)
REM ===========================================================================
REM Create table product_descriptions, which contains NVARCHAR2 columns for
REM NLS-language information.
REM ===========================================================================
CREATE TABLE product_descriptions
( product_id NUMBER(6)
, language_id VARCHAR2(3)
, translated_name NVARCHAR2(50)
CONSTRAINT translated_name_nn NOT NULL
, translated_description NVARCHAR2(2000)
CONSTRAINT translated_desc_nn NOT NULL
CREATE UNIQUE INDEX prd_desc_pk
ON product_descriptions(product_id,language_id) ;
ALTER TABLE product_descriptions
ADD ( CONSTRAINT product_descriptions_pk
PRIMARY KEY (product_id, language_id));
ALTER TABLE orders
ADD ( CONSTRAINT orders_sales_rep_fk
FOREIGN KEY (sales_rep_id)
REFERENCES hr.employees(employee_id)
ON DELETE SET NULL
ALTER TABLE orders
ADD ( CONSTRAINT orders_customer_id_fk
FOREIGN KEY (customer_id)
REFERENCES customers(customer_id)
ON DELETE SET NULL
ALTER TABLE warehouses
ADD ( CONSTRAINT warehouses_location_fk
FOREIGN KEY (location_id)
REFERENCES hr.locations(location_id)
ON DELETE SET NULL
ALTER TABLE customers
ADD ( CONSTRAINT customers_account_manager_fk
FOREIGN KEY (account_mgr_id)
REFERENCES hr.employees(employee_id)
ON DELETE SET NULL
ALTER TABLE inventories
ADD ( CONSTRAINT inventories_warehouses_fk
FOREIGN KEY (warehouse_id)
REFERENCES warehouses (warehouse_id)
ENABLE NOVALIDATE
ALTER TABLE inventories
ADD ( CONSTRAINT inventories_product_id_fk
FOREIGN KEY (product_id)
REFERENCES product_information (product_id)
ALTER TABLE order_items
ADD ( CONSTRAINT order_items_order_id_fk
FOREIGN KEY (order_id)
REFERENCES orders(order_id)
ON DELETE CASCADE
enable novalidate
ALTER TABLE order_items
ADD ( CONSTRAINT order_items_product_id_fk
FOREIGN KEY (product_id)
REFERENCES product_information(product_id)
ALTER TABLE product_descriptions
ADD ( CONSTRAINT pd_product_id_fk
FOREIGN KEY (product_id)
REFERENCES product_information(product_id)
REM ===========================================================================
REM Create cross-schema synonyms
REM ===========================================================================
CREATE SYNONYM countries FOR hr.countries;
CREATE SYNONYM locations FOR hr.locations;
CREATE SYNONYM departments FOR hr.departments;
CREATE SYNONYM jobs FOR hr.jobs;
CREATE SYNONYM employees FOR hr.employees;
CREATE SYNONYM job_history FOR hr.job_history;
REM ===========================================================================
REM Create sequences
REM ===========================================================================
CREATE SEQUENCE orders_seq
START WITH 1000
INCREMENT BY 1
NOCACHE
NOCYCLE;
REM ===========================================================================
REM Need commit for PO
REM ===========================================================================
COMMIT;And yes, you must install at least Oracle SE to get completely this sample schemas on your file system :( -
How to create 9i db without sample schema?
I have (finally) gotten 9iR2 installed on RH 7.3.
During installation I created sample database instance TEST.
I then used dbca to create a second instance JSDB.
I did not see (but may have missed) dbca questions regarding wether or not to create/load sample database schema.
How best to create a database without the sample database schema?
If it can not be done, how best to expunge the sample database schema and all related litter?
There seems to be tables for SCOTT, HR, OE, SH, PM.
Thanks
R.Parr
Temporal ArtsTo drop SCOTT schema, run the batch file/shell script:
ORACLE_HOME\BIN\DEMODROP
To drop HR schema, run SQL script:
ORACLE_HOME\DEMO\SCHEMA\HUMAN_RESOURCES\HR_DROP.SQL
There are a number of other sample schema scripts to drop the other schemas installed with Oracle9i. If you can't find them easily, read the Sample Schema Guide on http://tahiti.oracle.com/.
Alison -
Unable to create sample schema using response file
Installed oracle 11g r1 on Linux server using response file (silent mode). I wanted to install the sample schema for testing so I updated the sample_schemas section in $ORACLE_HOME/assistants/dbca/templates/dbcreate.dbc
<option name="SAMPLE_SCHEMA" value="true">
<tablespace id="USERS"/>
</option>
After the installation I noticed sample schemas HR, SH were not created.
- Do we have to manually create the sample schemas by running the individual scripts?
- Also could not find the master script mksample.sql in the $ORACLE_HOME/demo/schema directory.
Please let me know if I am missing any parameter in dbcreate.dbc.
Thank you,user504183 wrote:
Installed oracle 11g r1 on Linux server using response file (silent mode). I wanted to install the sample schema for testing so I updated the sample_schemas section in $ORACLE_HOME/assistants/dbca/templates/dbcreate.dbc
<option name="SAMPLE_SCHEMA" value="true">
<tablespace id="USERS"/>
</option>
After the installation I noticed sample schemas HR, SH were not created.
- Do we have to manually create the sample schemas by running the individual scripts?
- Also could not find the master script mksample.sql in the $ORACLE_HOME/demo/schema directory.
Please let me know if I am missing any parameter in dbcreate.dbc.
Thank you,You can't install manually the sample schemas since they come in a "pluggable tablespace" Examples which is automatically appended to your database by DBCA. If you would miss choosing the option for the same, you would need to get them created through the Examples Media CD and follow the instructions given here.
http://download.oracle.com/docs/cd/B28359_01/server.111/b28328/installation.htm#I4367
HTH
Aman....
Maybe you are looking for
-
How can I properly attach an Email 'business card' signature?
Hi, I was wondering if there were any better ways to attach a business card signature with mail. Currently I have a small business card that I have optimized to around 60 kb, I use the signature feature in Mail to drag it in and add my standard busin
-
Hello QM masters, Is there a standard report to search the history of all usage decisions that have been taken on certain material or batch? Best regards, Tiago Magalhães
-
Adobe flash player not working correctly
I need help about flash player. I have problems with video files in every browser. It is playing, but it is not possible to move video, use fullscreen or change volume. How can i solve this problem? Thanks for help Lukas
-
Access denied error when starting DIAdem from LabVIEW
We are using the DIAdem Connectivity Toolkit in our application. Our application starts a DIAdem session to handle querying and datasheet creation. On a recent installation at a customer, our application was not able to communicate with DIAdem, i.e
-
Why does this work in MS SQL and not in Oracle
ALTER TABLE Stk DROP COLUMN ComCode; This BASIC statement works perfectly in MS SQL, but after 2 hours now, it simply refuses to work in Oracle, although the syntax seems correct, I get : ALTER TABLE Stk DROP COLUMN ComCode ORA-00905: missing keyword