oracle相关

oracle_shell_spool数据导出

oracle_shell_spool数据导出
exportdata_20150123_fl_sale_data.sh

sqlplus -s mcdm/passwd@ORCL </dev/null
alter session Enable parallel dml;
Alter  Table fl_sale_data            Parallel;
Alter  Table fl_sale_data            NOLOGGING;

set colsep '|' ;   
SET heading off;
set feedback off;
SET pageSIZE 0;
spool b.txt
select  /*+ parallel(a,4) */ to_char(user_id)||'|'||to_char(Password) from cap_user a where rownum<10;
spool off
exit
EOF

留言

您的邮箱地址不会被公开。 必填项已用 * 标注