直接插入的话,会报错字符过长,所以设置成了clob类型,代码中要怎么设置呢?
SQLQuery query = null;
String params[] =sqlSources.get(paramID).split(",");
query = jbpmContext.getSession().createSQLQuery(sqlSources.get(sqlID));
for(int i=0,len = params.length; i<len; i++){
if(i==len-1){
query.setLong(i,Long.parseLong(formValue.get(params[i])));
}else{
//log.info(params[i] +":===:"+formValue.get(params[i]));
query.setString(i, formValue.get(params[i]));
}
}
int row = query.executeUpdate();
result = ( row == 1 ? true : false);
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…