日期:2014-05-16  浏览次数:20641 次

Linux中用脚本导出数据

sqlplus -s $username/$password <<EOF

SET COLSEP ','

SET feedback off

SET newpage none

SET pagesize 0

SET linesize 10000

SET verify off

SET pagesize 0

SET term off

SET trims ON

SET heading off

SET trimspool ON

SET trimout ON

SET timing off

SET verify off

spool /$path/$table.txt

SELECT * form table1

spool off

EOF