java 调用 sql,脚本,用以实现备份库

来源:互联网 发布:win10双系统安装ubuntu 编辑:程序博客网 时间:2024/05/16 18:46
String   statement   ="sqlplus   username/password@sid   @c:/test.sql";  
   
  try   {  
  Runtime.getRuntime().exec(statement);  
  }   catch   (IOException   e)   {  
  e.printStackTrace();  
  }