标签:inf nbsp clob har exception str prepare ble 代码
CREATE OR REPLACE PROCEDURE update_log_proc(plids IN VARCHAR2,pparas IN NCLOB,msg IN NCLOB) AS BEGIN UPDATE g3_log_info SET paras=pparas,xml_data=msg WHERE lids=plids; END; 数据库执行: execute update_log_proc(‘00000‘,‘clerk‘,‘msg‘) java代码调用: /** * 调用存储过程 更新日志数据 * @param lids 主键 * @param para 接口参数 * @param msg 返回信息 */ public static void callpProcedure(String lids,String para,String msg) { Connection connection = null; CallableStatement cs = null; try { connection = GsUtil.getConnection(); cs = connection.prepareCall(" call update_log_proc(?,?,?) "); cs.setString(1, lids); cs.setString(2, para); cs.setString(3, msg); cs.execute(); } catch (SQLException e) { e.printStackTrace(); } finally { try { if (cs != null) { cs.close(); } if (connection != null) { connection.close(); } } catch (SQLException e) { e.printStackTrace(); } } }
标签:inf nbsp clob har exception str prepare ble 代码
原文地址:https://www.cnblogs.com/lxh520/p/9012722.html