The Oracle HR example uses 10g, 11g, and oracle11g.

Source: Internet
Author: User

The Oracle HR example uses 10g, 11g, and oracle11g.

Oracle HR example users can create 10g, 11g

First, add the 10. SQL files in the attachment (see the end of the article) to this path:

$ ORACLE_HOME/demo/schema/human_resources

 

Script Name

Description

Hr_anz. SQL

Collects statistics on the tables in the schema.

Hr_code. SQL

Creates procedural objects in the schema.

Hr_comnt. SQL

Creates comments for each object in the schema.

Hr_cre. SQL

Creates the HR objects.

Hr_dn_c. SQL

Adds the distinguished name column used by Oracle Internet Directory to the employees and deployments tables.

Hr_dn_d. SQL

Drops the Oracle Internet Directory distinguished name column from employees and deployments.

Hr_drop. SQL

Drops the HR schema and all its objects.

Hr_idx. SQL

Creates indexes on the HR tables.

Hr_main. SQL

Main script for the HR schema; callother scripts.

Hr_popul. SQL

Populates the objects.

 

Then run the hr_main.sq file on SQL * PLUS.

A) SQL> @? /Demo/schema/human_resources/hr_main. SQL

B) Specify passwordForHR as parameter 1:

C) Enter valueFor1: hr

D) Specify default tablespeaceForHR as parameter 2:

E) Enter valueFor2: users

F) Specify temporary tablespaceForHR as parameter 3:

G) Enter valueFor3: temp

H) Specify passwordForSYS as parameter 4:

I) Enter valueFor4: runner

J) Specify log path as parameter 5:

K) Enter valueFor5: C:/oracle/product/10.1.0/db_1/RDBMS/log ($ ORACLE_HOME/rdbms/log in Linux)

 

You can run this command to check whether the HR user has been successfully created.

Desc dba_users;

Select username, account_status from dba_users;


Attachment address:

Http://download.csdn.net/detail/fuzhangpeng/7712823


Script Creation sequence for Oracle 10g hr users

It is estimated that the downloaded content is used in this way. The referenced page cannot be loaded into the answer:
Run the hr_main. SQL script in SQL-Plus.
Method: Enter:
> @ SQL Script directory \ hr_main. SQL
For example, @ c: \ SQL scrcept \ hr_main. SQL
Then the system prompts you to enter some Bound variables:
B) Specify password for HR as parameter 1:
HR user password:
C) Enter value for 1: hr

D) Specify default tablespeace for HR as parameter 2:
HR users' default tablespace:
E) Enter value for 2: users

F) Specify temporary tablespace for HR as parameter 3:
Default temporary tablespace for HR users:
G) Enter value for 3: temp

H) Specify password for SYS as parameter 4:
Enter the table space of the SYS User:
I) Enter value for 4: syspass

J) Specify log path as parameter 5:
Enter the log generation path:
K) Enter value for 5: C: \ oracle \ product \ 10.1.0 \ db_1 \ RDBMS \ log
This script should automatically call the table creation index and auxiliary script programs.

Oracle 11g r2 has hr users? How can I find it if I cannot find it? Is there a problem with the sample database I installed?

Log on to the database using sys or system, and run the command select * from dba_users; to check which users are there. If the user has HR in USERNAME, the account is locked, you can use
SQL> alter user Username identified by new password; Change user Password

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.