create directory dump_dir as 'd:\dump';
grant read,write on directory dump_dir to scott;
--在cmd下
expdp scott/1qaz2wsx directory=dump_dir dumpfile=tab.dmp tables=emp,dept
expdp system/1qaz2wsx directory = dump_dir dumpfile=schema.dmp schemas = scott,hr
expdp system/1qaz2wsx directory = dump_dir dumpfile = tablespace.dmp tablespaces = tbsp_1
expdp system/1qaz2wsx directory=dump_dir dumpfile=fulldatabase.dmp full=y
expdp scott/1qaz2wsx directory=dump_dir dumpfile=content.dmp content=data_only
expdp scott/1qaz2wsx directory=dump_dir dumpfile=query.dmp tables=dept query='where deptno=10'
impdp system/1qaz2wsx directory=dump_dir dumpfile=tab.dmp tables=scott.dept,scott.emp remap_schema=scott:system
impdp system/1qaz2wsx directory=dump_dir dumpfile=schema.dmp schemas=scott remap_schema=scott:system;
impdp system/1qaz2wsx directory=dump_dir dumpfile=tablespace.dmp tablespaces=tbsp_1
impdp system/1qaz2wsx directory=dump_dir dumpfile=fulldatabase.dmp full=y
impdp scott/1qaz2wsx directory=dump_dir dumpfile=sqlfile.dmp sqlfile=test.sql
impdp system/1qaz2wsx directory=dump dumpfile=tran_datafiles.dmp transport_datafiles='d:\OracleData\test.dbf'
--在sqlplus环境下
create table student
(stuno number(4),
stuname varchar2(20),
sex varchar2(4),
old number(4)
); ---在cmd环境下
sqlldr system/1qaz2wsx control=d:\data\student.ctl log=d:\data\stu_log

1001 东方 男 30
1002 开心 女 25
1003 JACK 男 23
1004 ROSE 女 20

--在sqlplus环境下
create table persons
(code number(4),
name varchar2(20),
sex varchar2(4),
old number(4)
); --在cmd环境下
sqlldr system/1qaz2wsx control=d:\data\persons.ctl

1005,east,女,26
1006,west,男,25
1007,happy,男,24
1008,mary,女,20

--创建目录
create directory dump_dir as 'd:\dump'; --给hr授权
grant read,write on directory dump_dir to hr; --在cmd下导出表
expdp hr/hr directory=dump_dir dumpfile=tab.dmp tables=employees
--在cmd下导入
impdp scott/1qaz2wsx directory=dump_dir dumpfile=tab.dmp tables=hr.employees remap_schema=hr:scott

吴裕雄--天生自然ORACLE数据库学习笔记:数据导出与导入的更多相关文章

  1. 吴裕雄--天生自然ORACLE数据库学习笔记:Oracle数据备份与恢复

    run{ allocate channel ch_1 device type disk format = 'd:\oraclebf\%u_%c.bak'; backup tablespace syst ...

  2. 吴裕雄--天生自然ORACLE数据库学习笔记:过程、函数、触发器和包

    create procedure pro_insertDept is begin ,'市场拓展部','JILIN'); --插入数据记录 commit; --提交数据 dbms_output.put_ ...

  3. 吴裕雄--天生自然ORACLE数据库学习笔记:PL/SQL编程

    set serveroutput on declare a ; b ; c number; begin c:=(a+b)/(a-b); dbms_output.put_line(c); excepti ...

  4. 吴裕雄--天生自然ORACLE数据库学习笔记:Oracle 11g的闪回技术

    alter system set db_recovery_file_dest_size=4g scope=both; connect system/1qaz2wsx as sysdba; archiv ...

  5. 吴裕雄--天生自然ORACLE数据库学习笔记:优化SQL语句

    create or replace procedure trun_table(table_deleted in varchar2) as --创建一个存储过程,传入一个表示表名称的参数,实现清空指定的 ...

  6. 吴裕雄--天生自然ORACLE数据库学习笔记:Oracle系统调优

    --修改 alter system set large_pool_size=64m; --显示 show parameter large_pool_size; select sum(getmisses ...

  7. 吴裕雄--天生自然ORACLE数据库学习笔记:用户管理与权限分配

    create user mr identified by mrsoft default tablespace users temporary tablespace temp; create user ...

  8. 吴裕雄--天生自然ORACLE数据库学习笔记:表分区与索引分区

    create table ware_retail_part --创建一个描述商品零售的数据表 ( id integer primary key,--销售编号 retail_date date,--销售 ...

  9. 吴裕雄--天生自然ORACLE数据库学习笔记:其它数据对象

    create index emp_deptno_index on emp(deptno) pctfree tablespace users; create bitmap index emp_salar ...

随机推荐

  1. bit Buffer

    在音频流解析过程中,常常会涉及到顺序读取某些bit的操作. #include<stdio.h> typedef struct _BIT_BUF { unsigned char buffer ...

  2. py2

    函数相关的 # 生成器相关的# 例1 ll = sum(i for i in range(100000000)) #生成器占资源少 # 例2 def demo(): for i in range(4) ...

  3. 传奇脚本中 SendMsg 编号说明

    0 1 2 3 4 5 60对全服人说1.发送普通红色广播信息. 2.发送普通红色广播信息,并显示NPC名称. 3.发送普通红色广播信息,并人物NPC名称. 4.在NPC头顶,显示普通说话信息. 5. ...

  4. Nodejs的Gruntjs使用一则

    Gruntjs是前端项目构建工具,基于nodejs命令.有些js项目是基于Gruntjs构建的,如Jquery. Gruntjs主要功能有: 1.合并文件. 2.压缩html,js,css,图片文件. ...

  5. Java连载82-Set、Collection、List、Map的UML演示

    一.UML演示Collection集合的继承结构图 二.Set集合 1.List存储元素的特点:有序可重复.有序,存进去是什么顺序,拿出来还是什么顺序. 2.Set存储元素的特点:无序不可重复,存进去 ...

  6. springboot 框架 - helloword

    功能:浏览器发送hello请求,服务器接收请求并处理,返回hello word字符串 一.创建一个maven项目 二.在pom.xml文件中添加依赖导入springboot框架运行需要的依赖 < ...

  7. 树莓派实现SIM868 ppp拨号上网

    环境:raspbian-stretch(2018-06-27) 树莓派:3代B型 SIM868模块具有GPRS数据传输功能(2G网络),但是模块是通过AT指令控制的,在树莓派上用AT指令控制会非常不方 ...

  8. 安卓之视图View的基本属性

    一.在xml布局文件中常用的属性定义   (1)  id:指定该视图的编号   (2)  layout_width:指定该视图的宽度可以是具体的dp值:可以是match_parent,表示与上级视图一 ...

  9. python 创建虚拟环境:bat实现一键

    1.New a python project 2.cd %project.home%切换到项目根目录3.运行setup.bat创建venv虚拟环境 (注意内网运行setup.bat需要手动将requi ...

  10. ZOJ1008 Gnome Tetravex

    DFS+剪枝~ #include<bits/stdc++.h> using namespace std; ][]; int N; int cnt; ]; ]; unordered_map& ...