shell编程中如果向oracle中插入数据之类的,需要先把执行语句放到文件中,然后再@这个文件执行

有如下俩种方式供参考:


SQL=`sqlplus user/pwd@orains <<EOF
@Sqlfile
exit
EOF
`
或者
echo "exit"|sqlplus user/pwd@orains @sqlfile

 

相关文章:

  • 2021-11-12
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-05-11
  • 2021-12-05
  • 2022-12-23
  • 2022-12-23
  • 2021-09-23
  • 2021-09-10
  • 2022-12-23
相关资源
相似解决方案