Loading data from CSV into HSQLDB with a sequence

I’m attempting to load some data into an HSQLDB database using Liquibase 1.9.5. I have a loadData command as follows:

In my CSV data file I'm attempting to set the ID value to the next value from an existing sequence:
    id,name,description next value for SEQ_ITEM_TYPE_ID,Test Name,A test description
However, this doesn't work as it generates the following SQL:
    INSERT INTO LIST_ITEM_TYPE (id, description, name) VALUES ('next value for SEQ_ITEM_TYPE_ID', 'A test description', 'Test Name')
This is almost correct, except that the single quotes that Liquibase added around the "next value for SEQ_ITEM_TYPE_ID" part cause HSQLDB to give the following error:
    java.sql.SQLException: data exception: invalid character value for cast
If I remove the sinqle quotes and run that SQL manually, it works as expected.

So, my question is, how do I use the Liquibase loadData command pulling data from a CSV file while populating one of the columns from a sequence?


I’d like this too (with oracle). Did you find a solution?

Would the following proposal work as a new Liquibase feature?

a new column type of SEQUENCE, and you’d probably need an optional attribute for the sequence name.

Best Regards,

or more generally ( and less portably) a type of SQL, where the cell data is as moniker tried?

or for type of SEQUENCE, the id column in the csv could contain the sequence name

found Nathan’s answer on stack overflow to  similar question. trying a few things, meanwhile, wrestling with checksums

All sorted out of the box:

I too face this issue. The above solution doesn’t seem to work for me.

I tried to use sequence.nextval in csv file but getting exception.


Then tried to use type=“COMPUTED” when defining columns in and use the function in CSV. But still it gives exception


ORA-01722: invalid number
ORA-06512: at line 4
          Caused By: ORA-01722: invalid number