现将历史数据从生产库迁移到备用库,并删除生产库的历史数据
[php]
spool log.txt;
select to_char(sysdate, 'yyyy-mm-dd HH24:MI:SS') from dual;
copy from user/pwd@product to user/pwd@history appenda using select * from a where a_datewhenever sqlerror exit
SQL> select to_char(sysdate, 'yyyy-mm-dd HH24:MI:SS') from dual;
copy from user/pwd@product to user/pwd@history appenda using select * from a where a_date
Array fetch/bind size is 15. (arraysize is 15)
Will commit when done. (copycommit is 0)
Maximum long size is 80. (long is 80)
ERROR:
ORA-12154: TNS:could not resolve service name
[/php]
try"php" instead of "code"