database-rider icon indicating copy to clipboard operation
database-rider copied to clipboard

Datasets not working with postgresql array column

Open MariaMigl opened this issue 3 years ago • 4 comments

Hello.

I am currently working on a project where some of the db tables are array of varchar. The database server is postgresql and and the configuration is working just fine with hibernate and the application. However while running the tests and inserting data with @Dataset I am getting the following exception:

Caused by: org.dbunit.dataset.NoSuchColumnException: table_name.COLUMN_NAME - (Non-uppercase input column: column_name) in ColumnNameToIndexes cache map. Note that the map's column names are NOT case sensitive.

I've debug the application and made sure the column actually exists and the schema is correctly created. I've done some investigation and some people mention this as a limitation of DbUnit for this specific data type.

Is there a way currently to work with this array or to use database-rider I would have to go with other data type in my table schema?

I am currently running the tests with com.github.database-rider:rider-cdi:1.35.1 and it is a quarkus application. To test we are running postgresql with testcontainers.

MariaMigl avatar Mar 22 '23 07:03 MariaMigl

Hi @Ryukamusa , afaik it should work, i remember using it in one of my past projects. Could you please provide a reproducer, then it would be easier for me to look into it.

PS_ [off-topic] are you using Testcontainers via TestResource or rather Devservices in Quarkus for testing?

coiouhkc avatar May 08 '23 15:05 coiouhkc

Same problem. We use spring-boot-test 3.0.2 + dbrider 1.36.0 + testcontainers 1.17.6 + postgres + liquibase

redbore avatar Jun 01 '23 14:06 redbore

Same problem. spring 3.1.0, dbrider 1.41.0, testcontainers 1.18.3. It doesn't work with 'model_years' and 'trims' columns image

denysbar avatar Nov 16 '23 22:11 denysbar