以下内容为填报脚本,烦请查下是否有问题
var conn = null;
var user1=param["_USER_"]; //登录用户
var datetime1= toSQLDate(now(),DType.DATE_TIME); //操作时间
var success = 0;
var success1 = 0;
try {
conn = createConnection(CONNECTION, "005 xxxx/xxxx");
var pstmt1 = conn.prepareStatement("delete from table1 where col1 is not null and col2=?");
pstmt1.setString (1,user1);
pstmt1.executeUpdate();
var pstmt = conn.prepareStatement("insert into table1 (col1, col2,col3 ) values (?,?,?)");
pstmt.setString (1,文本参数1.value);
pstmt.setString (2,user1);
pstmt.setString (3,datetime1);
pstmt.executeUpdate();
var pstmt3 = conn.prepareStatement("delete from q_r_sv_product_snpn where col1 is not null and create_name=?");
pstmt3.setString (1,user1);
pstmt3.executeUpdate();
var pstmt4=conn.prepareStatement("insert into q_r_sv_product_snpn (col1, col2,col3) select regexp_split_to_table(col1,' ') col1,col2,col3 from table1 where col1 is not null and col2=?")
pstmt4.setString (1,user1);
success=pstmt4.executeUpdate();
conn.commit();
if(success > 0){
try {
debug("导入成功!!!");
conn.close();
}catch(e){
try {
if(conn != null) {
conn.rollback();
}
}
catch(e1) {
debug("导入失败: " + e1);
}
debug("导入失败:" + e);
}
}else {