Ronald
Nov 21st, 2007, 04:57 AM
When I use the Hibernate configuration I get the following exception:
Hibernate: select this_.ID as ID0_0_, this_.version as version0_0_, this_.STATUS as STATUS0_0_, this_.JOB_NAME as JOB4_0_0_, this_.JOB_KEY as JOB5_0_0_ from BATCH_JOB this_ where case when this_.JOB_KEY is NULL then 'Simple' when this_.SCHEDULE_DATE is NULL then 'Default' else 'Scheduled' end='Default' and (this_.JOB_NAME=? and this_.JOB_KEY=?)
Hibernate: insert into BATCH_JOB (ID, version) values (null, ?)
2007-11-21 10:23:48,890 ERROR JDBCExceptionReporter - Attempt to insert null into a non-nullable column: column: JOB_NAME table: BATCH_JOB in statement [insert into BATCH_JOB (ID, version) values (null, ?)]
When I modify the sql file packaged with Spring batch to the following I don't get the exception.
CREATE TABLE BATCH_JOB (
ID BIGINT IDENTITY PRIMARY KEY ,
VERSION BIGINT,
JOB_NAME VARCHAR(100) ,
JOB_KEY VARCHAR(20) ,
SCHEDULE_DATE DATE ,
STATUS VARCHAR(10) );
I think this is an issue in Spring Batch, but I'm not sure. Maybe I'm using a wrong configuration.
Is this a known issue?
Hibernate: select this_.ID as ID0_0_, this_.version as version0_0_, this_.STATUS as STATUS0_0_, this_.JOB_NAME as JOB4_0_0_, this_.JOB_KEY as JOB5_0_0_ from BATCH_JOB this_ where case when this_.JOB_KEY is NULL then 'Simple' when this_.SCHEDULE_DATE is NULL then 'Default' else 'Scheduled' end='Default' and (this_.JOB_NAME=? and this_.JOB_KEY=?)
Hibernate: insert into BATCH_JOB (ID, version) values (null, ?)
2007-11-21 10:23:48,890 ERROR JDBCExceptionReporter - Attempt to insert null into a non-nullable column: column: JOB_NAME table: BATCH_JOB in statement [insert into BATCH_JOB (ID, version) values (null, ?)]
When I modify the sql file packaged with Spring batch to the following I don't get the exception.
CREATE TABLE BATCH_JOB (
ID BIGINT IDENTITY PRIMARY KEY ,
VERSION BIGINT,
JOB_NAME VARCHAR(100) ,
JOB_KEY VARCHAR(20) ,
SCHEDULE_DATE DATE ,
STATUS VARCHAR(10) );
I think this is an issue in Spring Batch, but I'm not sure. Maybe I'm using a wrong configuration.
Is this a known issue?