Oracle Database User Creation and permission allocation

Source: Internet
Author: User
1. parameter settings during Database Installation

The following database version is Oracle 9i ( 9.2.0 ), When the database is installed, the database system will create a database instance, where: The installation directory is/Oracle, the database name and database Sid are entered: ora9i, where the character set must be: zhs16gbk (otherwise, it will be difficult to perform Chinese operations in the future ).

2. Database User Creation and permission allocation

After the database is installed, there are two system-level users:

1. the default system password is Manager.

2. The default sys password is change_on_install.

Find the sqlplus program in/Oracle/product/9.2/bin in the installed database directory and run:./sqlplus system/manager @ ora9i


Use the System user to create your own users and permissions. The SQL statement is as follows:

1. Create a user:

Create User Username identified by PWD default tablespace users temporary tablespace temp;

2. user authorization

Grant connect, resource, DBA to business;

3. Submit

Commit;

3. Use a database script to create a database

As described above, use sqlplusUsernameLog on to the console and enter @ The Script Name for creating the database. SQL enter to create tables, views, and stored procedures in the database.

Note: The above user creation process allows the user's table to have n multiple temporary tables automatically generated by the system.

SQL statement used to create a tablespace:

Create tablespace "msnrobot"
Logging
Datafile '/opt/ora9/oradata/Oracle/msnrobot. dbf' size 10 m
Extent management local segment space management auto

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.