首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 数据库 > oracle >

写一个shell脚本执行sql语句解决方法

2012-01-06 
写一个shell脚本执行sql语句写一个shell脚本执行insert into tt(id,name) select id,name from yy语句test

写一个shell脚本执行sql语句
写一个shell脚本执行insert into tt(id,name) select id,name from yy语句
test.sh

#!/bin/bash
sqlplus -s 'cisf/cisf23@cisfkfdb'<<EOF
set feed off
set heading off;
set feedback off;
set verify off;
insert into tt(id,name) select id,name from yy;
EOF

没写过shell脚本,大家帮我看看!

[解决办法]
没什么大问题,就是在 EOF 之前,加一个 commit;

热点排行