Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Clob myClob = CLOB.createTemporary(sql.getConnection(), false, CLOB.DURATION_SESSION);
- while ((row = reader.readNext()) != null) {
- myClob.truncate(0)
- myClob.setString(1,row[17])
- def stmt = /
- MERGE INTO my_table a
- USING (
- SELECT ${row[0]} id,
- ${myClob} clob_column
- FROM dual) e
- ON (a.id = e.id)
- WHEN MATCHED THEN
- UPDATE SET
- a.clob_column = e.clob_column
- /
- def runsql = sql.execute(stmt)
- ${myClob ?: null}
- ${if(myClob.length() > 0) then myClob else null}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement