I am inserting a large string into a CLOB
column. The string is (in this instance) 3190 characters long - but can be much larger.
The string consists of xml data - sometimes the data will commit, sometimes i get the error. The error occurs roughly 50% of the time.
Even string which contain over 5000 characters will sometimes commit with no problem.
Unsure where to go next as i am under the impression that CLOB
is the best data type for this data.
I have tried LONG
LONG RAW
Someone suggested using XMLTYPE
however that does not exist in my version of Oracle (11g - 11.2.0.2.0)
My insert statement:
INSERT INTO MYTABLE(InterfaceId, SourceSystem, Description, Type, Status, StatusNotes, MessageData, CreatedDate, ChangedDate, Id) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
MessageData is the CLOB
column where the error is occuring, i have tried commiting without this data populated and it works.
Error
ORA-01461: can bind a LONG value only for insert into a LONG column