I got a column message with data_type = VARCHAR2. It already has some data stored. I want this column to be of type NCLOB. Code-Set for this column should be UTF-8.
I did the following:
tempmessage
to my table of type NCLOBtempmessage
with messagetempmessage
to messageThen i tried out my integration tests and i got the exception: java.sql.BatchUpdateException: ORA-01400: Insert of NULL into ("BATCH_LOG"."MESSAGEOLD") not possible.
What have I done wrong?
The original column was defined as NOT NULL
, when you renamed that to MESSAGEOLD
, this constraint was kept. You need to remove the NOT NULL constraint from the MESSAGEOLD
column:
ALTER TABLE foo MODIFY MESSAGEOLD NULL;