背景:oracle正式库通过exp命令导出的dmp备份包,现在通过imp命令还原到测试库,测试库上面的表数据全部不要,要用新的. 方法:先删除用户.用户所在表空间,再新建用户和表空间,再imp导入. 过程: 1.用plsql查看用户的权限等信息并备份,例如 -- Create the user create user testuser;-- Grant/Revoke object privileges grant execute on SYS.DBMS_JOB to testuser;-- Gr
查看当前用户的缺省表空间 SQL>select username,default_tablespace from user_users; 查看当前用户的角色 SQL>select * from user_role_privs; 查看当前用户的系统权限和表级权限 SQL>select * from user_sys_privs; SQL>select * from user_tab_privs; 查看用户下所有的表 SQL>select * from user_tables;