Oracle导入数据需要哪些权限

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Oracle导入数据需要哪些权限相关的知识,希望对你有一定的参考价值。

1.Oracle中,用某一用户导入数据时具体需要哪些权限?
2.grant create session to xyz(用户名) on abc(表空间名),执行时报错说没有有效权限是怎么回事
不用dba权限可不可以,这样不安全

要先区别:dba<>sysdba,建议使用DBA操作。使用其它权限实际管理时,比较不方便。原因如Oracle所述。当然决定因素:主要是由导出导入的内容所决定你需要的最小权限集。 文章显示:IMP_FULL_DATABASE ,EXP_FULL_DATABASE 最终都给到了dba

IMPORT

To use Import, you need the privilege CREATE SESSION to log on to the Oracle
database server. This privilege belongs to the CONNECT role established during
database creation.
You can do an import even if you did not create the export file. However, keep in
mind that if the export file was created by a user with EXP_FULL_DATABASE
privilege, then you must have IMP_FULL_DATABASE privilege to import it. Both of
these privileges are typically assigned to DBAs.

EXPORT:

To use Export, you must have the CREATE SESSION privilege on an Oracle
database. To export tables owned by another user, you must have the EXP_FULL_
DATABASE role enabled. This role is granted to all DBAs.

If you do not have the system privileges contained in the EXP_FULL_DATABASE
role, you cannot export objects contained in another user’s schema. For example,
you cannot export a table in another user’s schema, even if you created a synonym
for it.
参考技术A 最大权限sysdba 参考技术B grant connect,resoure to user;
这2个权限就够了

Oracle数据库使用DBLINK导入远程Oracle数据库信息

    --1. 查询DBLINK权限
    select * from sys.user_sys_privs t where t.privilege like upper(%link%);
    --2. 赋予DBLINK权限
    grant CREATE PUBLIC DATABASE LINK,DROP PUBLIC DATABASE LINK to demobase;
    --3. 查询创建的DBLINK连接
    select * from DBA_DB_LINKS;
    --4. 创建DBLINK连接
    create public database link to_db11 connect to demobase identified by demobase using  (DESCRIPTION =
       (ADDRESS_LIST =
         (ADDRESS = (PROTOCOL = TCP)(HOST = 11.11.11.11)(PORT = 1521))
       )
       (CONNECT_DATA =
         (SERVER = DEDICATED)
         (SERVICE_NAME = demo)
       )
     );
    --5. 删除DBLINK连接
    drop public database link to_db11;

 

    --查询远程数据库的信息
    select * from demobase.my_demo@to_db11;
    --复制表信息
    create table my_test as select * from my_demo where 1=2 ;
    --全表复制
    create table my_test as select * from demobase.my_demo@to_db11;
    --创建临时表,复制LOB字段
    create global temporary table my_temp as select * from demobase.my_demo@to_db11;

 

以上是关于Oracle导入数据需要哪些权限的主要内容,如果未能解决你的问题,请参考以下文章

oracle数据库的导入对于用户需要啥权限? 必须用导出时的用户导入么?

ORACLE数据库,imp导入表时,说要有DBA权限,怎么办?

oracle数据库删除、还原。

Oracle数据库导入与导出方法简述

ORACLE导入导出命令 GRANTS=Y会是啥结果

如何用PLSQL软件向oracle数据库导入数据