By default, hr users and tables are not created. You can create a table by using dbca or script.
Now I create hr users and tables in script Mode
1. Obtain the hr user script from the Internet
2. Add the script to the $ Oracle_HOME/demo/schema/human_resources directory.
Hr_anz. SQL hr_comnt. SQL hr_dn_c. SQL hr_drop. SQL hr_main. SQL
Hr_code. SQL hr_cre. SQL hr_dn_d. SQL hr_idx. SQL hr_popul. SQL
Put the preceding script in the $ ORACLE_HOME/demo/schema/human_resources directory.
- Cd $ ORACLE_HOME/demo/Schema/Human_resources
- [Root @ IM-8-201 human_resources] # sqlplus sys/sysAsSysdba @ hr_main. SQL
- SQL * Plus: Release 10.2.0.4.0-ProductionOnTue Nov 15 21:40:44 2011
- Copyright (c) 1982,200 7, Oracle.AllRights Reserved.
- ConnectedTo:
- OracleDatabase10g Enterprise Edition Release 10.2.0.4.0-64bit Production
- WithThe Partitioning, OLAP, Data MiningAnd RealApplication Testing options
- SpecifyPassword ForHRAsParameter 1:
- Enter valueFor1: hr
- SpecifyDefaultTablespeaceForHRAsParameter 2:
- Enter valueFor2:User
- SpecifyTemporaryTablespaceForHRAsParameter 3:
- Enter valueFor3:Temp
- SpecifyPassword ForSYSAsParameter 4:
- Enter valueFor4: sys
- Specify log pathAsParameter 5:
- Enter valueFor5:/home/oracle
- ..............................
- PL/SQLProcedureSuccessfully completed.
- PL/SQLProcedureSuccessfully completed.
- SQL>
3. Verification
- SQL>SelectTable_nameFromUser_tables;
- TABLE_NAME
- ------------------------------
- REGIONS
- LOCATIONS
- Administrative ments
- JOBS
- EMPLOYEES
- JOB_HISTORY
- COUNTRIES
- 7RowsSelected.