java prepared statement java.sql.SQLException:ORA-01747

时间:2014-01-23 17:45:14

标签: java sql oracle

大家好,你能告诉我为什么我通过这个查询得到以下错误吗?

 private String updateMoneyDealsEdit = "update moneydeals set mask = substr(mask,0,?)||'1'||substr(mask,?,32), " +
"ITI=?,UTI=?,idCONTROPARTE=?,'',SDR=?,USI=?,CONFIRMATIONTIME=?,CONFIRMATIONMETHOD=?,EVENTDATE=?, " +
" CONFIRMATIONDATE=?,codicemessaggio=?,'',PARENTCODICECONTRATTO=?,'I',RESEND=1 where CODINTORD=? and CODICEMESSAGGIO=? and EVENTCODE=? and EVENTDATE=? ";

1 个答案:

答案 0 :(得分:5)

因此,您正在运行的更新格式很好,显示缺少列名称的位置:

update moneydeals 
    set mask = substr(mask,0,?)||'1'||substr(mask,?,32), 
        ITI=?,
        UTI=?,
        idCONTROPARTE=?,
        '',    -- Missing column name
        SDR=?,
        USI=?,
        CONFIRMATIONTIME=?,
        CONFIRMATIONMETHOD=?,
        EVENTDATE=?,
        CONFIRMATIONDATE=?,
        codicemessaggio=?,
        '',    --Missing column name
        PARENTCODICECONTRATTO=?,
        'I',   --Missing column name
        RESEND=1 
  where CODINTORD=? 
    and CODICEMESSAGGIO=? 
    and EVENTCODE=? 
    and EVENTDATE=?