Posted on 2009-01-05 10:01
☆ 阅读(456)
评论(0) 编辑 收藏 所属分类:
J2SM
主要用到CallableStatement 类,用来执行存储过程。
/**调用脚本*/
String date = repairDate.replace("-", "");
String packSql ="{call biss.biss_fee_query_page.dm_call_his_sh('" + areaId + "','"+date+"')}" ;
Connection con = dc.getConnection();
CallableStatement stmt = con.prepareCall(packSql);
stmt.execute();
stmt.close();
call biss.biss_fee_query_page.dm_call_his_sh('" + areaId + "','"+date+"'),call是关键字,
biss为用户,biss_fee_query_page包名,dm_call_his_sh过程名,
areaId 、date为该存储过程的两个参数。