Hello,
i'm new JOOQ user and during a loadCSV, jooq attemps to insert a null value
(my field is numeric and not nullable so i have an exception) , the value
for the field in CSV is empty
I tried the nullString parameter without success
CSV (it's the third value) :
ABJ;NOVA100;
ABJ;PLAS148; 46
the java code:
ctx.loadInto(Tables.PRODUIT_ETABLISSEMENT)
.onDuplicateKeyUpdate()
.loadCSV(temporaryFileSQL)
.fields(Tables.PRODUIT_ETABLISSEMENT.ETACODE,Tables.PRODUIT_ETABLISSEMENT.PSCODE,
Tables.PRODUIT_ETABLISSEMENT.PSSTK)
.ignoreRows(0)
.nullString("{null}")
.quote('\'')
.separator(';')
.execute();
the exception :
org.jooq.exception.DataAccessException: SQL [insert into
`ubipharm02`.`produit_etablissement` (`etacode`, `pscode`, `psstk`) values
(?, ?, ?) on duplicate key update
`ubipharm02`.`produit_etablissement`.`psstk` = ?]; (conn=249564) Column
'psstk' cannot be null
i don't understand why jooq remplace the empty by null
Thank you
--
You received this message because you are subscribed to the Google Groups "jOOQ
User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jooq-user/80e5e711-2e0e-4e5d-8010-4170a6310d73n%40googlegroups.com.