1. Create user
You need to log on to the database with the system user first because the system user has permissions to create other users.
syntax [Create users]: Create user username identified by password [i.e. password];
Example: Create user dhjw identified by 123456;
syntax [change users]: Alter user username identified by password [change password];
Example: Alter user DHJW identified by DHJW;
2. Delete users
Syntax: Drop user username;
Example: Drop user dhjw;
If the user owns the object, it cannot be deleted directly, otherwise an error value will be returned. Specifies the keyword cascade, which removes all objects from the user and then deletes the user.
Syntax: Drop user username cascade;
Example: Drop user DHJW cascade;
3. Authorized users have certain roles
Oracle provides the default three standard roles of Connect (connection role), resource (Resource role), DBA (Database Administrator role), and of course users can create their own roles, which are no longer in detail.
Authorization command:
Syntax: Grant connect, resource to user name;
Example: Grant connect, resource to DHJW;
Revoke permission Command
Syntax: Revoke connect, resource from user name;
The following: Revoke connect, resource from DHJW;
4. Import and Export commands
Import: Imp username/password @ instance name file= the absolute path to the DMP file to import log= log storage path Full=y ignore=y
Example: Imp dhjw/[email protected] file=c:\users\dell\desktop\ziyue_dh_20180308120000.dmp log=c:\data\dh_jw.log full=y Ignore=y
Export:
Full export of database test, user Name System Password Manager exported to D:\daochu.dmp
Exp system/[email protected] rows=y indexes=y compress=n buffer=65536 feedback=100000full=y File=d:\daochu. DMP Log=d:\daochulog.txt owner= (Ecc_biz,ecc_customer)
Oracle create user, authorization, import, Export command summary