Detailed explanation of the entire process of creating user permissions in Oracle

Source: Internet
Author: User

This article describes how to create user permissions in Oracle by creating a table. The following code is mainly used to compile the Oracle user creation permission, hoping to help you.

Note: Each language is executed separately and must end with a semicolon;

 
 
  1. // Create a space
  2. CreateTablespace test
  3. Datafile'C: \ oracle \ oradata \ orcl9 \ test. dbf' Size50 M
  4. DefaultStorage (initial 500 K
  5. Next500 K
  6. Minextents 1
  7. Maxextents unlimited
  8. Pctincrease 0 );
 
 
  1. // Create user permissions in Oracle
  2. // Create a user
  3. Create UserLxg identifiedByLxgDefaultTablespace test;
  4. // Authorization
  5. GrantResource,Connect, DbaToTest;
 
 
  1. // Delete the tablespace
  2. DropTablespace"Space name"Including contentsAndDatafiles

Delete a user

 
 
  1. drop user "lxg" cascade 

Add tablespace

 
 
  1. alter tablespace chinawater add datafile 'c:\oracle\oradata\orcl9\ADDCHINAWATER.dbf' size 200M 

Create user

 
 
  1. create user userName identified by password

Create userName and password

2

Authorize a user

 
 
  1. GrantDbaToLxg;-- Grant DBA Permissions 
  2. GrantUnlimited tablespaceToLxg;-- Grant unlimited tablespace 
  3. Grant Select Any Table ToLxg;-- Grant query to any table 
  4. Grant Select AnyDictionaryToLxg;-- Grant query to any dictionary 
 
 
  1. grant dba to lxg;  
  2. grant unlimited tablespace to lxg;  
  3. grant select any table to lxg;  
  4. grant select any dictionary to lxg; 

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.