Without addBatch / executeBatch my program runs without problems:
[main] Start
[main] tickerSymbolExtern='monetdb'
[main] Start MonetDB
[main] database table COUNTRY - 200 rows in total
[main] database table TIMEZONE - 11 rows in total
[main] database table COUNTRY_STATE - 500 rows so far
[main] database table COUNTRY_STATE - 600 rows in total
[main] database table CITY - 500 rows so far
[main] database table CITY - 1000 rows so far
[main] database table CITY - 1500 rows so far
[main] database table CITY - 1800 rows in total
[main] database table COMPANY - 500 rows so far
[main] database table COMPANY - 1000 rows so far
[main] database table COMPANY - 1500 rows so far
[main] database table COMPANY - 2000 rows so far
[main] database table COMPANY - 2500 rows so far
[main] database table COMPANY - 3000 rows so far
[main] database table COMPANY - 3500 rows so far
[main] database table COMPANY - 4000 rows so far
[main] database table COMPANY - 4500 rows so far
[main] database table COMPANY - 5000 rows so far
[main] database table COMPANY - 5400 rows in total
[main] duration in seconds: 52
[main] End MonetDB
[main] End
With addBatch / executeBatch and a batch size of 1000 I get the following error:
[main] Start
[main] tickerSymbolExtern='monetdb'
[main] Start MonetDB
[main] database table COUNTRY - 200 rows in total
[main] database table TIMEZONE - 11 rows in total
[main] database table COUNTRY_STATE - 500 rows so far
[main] database table COUNTRY_STATE - 600 rows in total
[main] database table CITY - 500 rows so far
[main] database table CITY - 1000 rows so far
[main] database table CITY - 1500 rows so far
java.sql.BatchUpdateException: Error(s) occurred while executing the batch, see next SQLExceptions for details
at nl.cwi.monetdb.jdbc.MonetStatement.executeBatch(Unknown Source)
at ch.konnexions.db_seeder.jdbc.AbstractJdbcSeeder.createDataInsert(AbstractJdbcSeeder.java:501)
at ch.konnexions.db_seeder.jdbc.AbstractJdbcSeeder.createData(AbstractJdbcSeeder.java:404)
at ch.konnexions.db_seeder.jdbc.AbstractJdbcSeeder.createData(AbstractJdbcSeeder.java:362)
at ch.konnexions.db_seeder.DatabaseSeeder.main(DatabaseSeeder.java:141)
Processing of the script was aborted, error code=1
Both times the connection runs with autoCommit.