I have a project which uses jooq + postgres with multiple tables and relations between them.
while I was creating a select query with jooq I had to use arrayAgg for my specific scenario.
dslContext.select(arrayAgg(tableName.INTEGER_LETS_SAY).as("static_name")
the specific column INTEGER_LETS_SAY is nullable.
when the results passed in arrayAgg are all null then the response of the postgres is '{null}' ( tested with getQuery().getSql() ) but the where statement cannot return true for all the methods I tried.
for example :
field("static_name", Long[].class).isNull()field("static_name", Long[].class).equal(new Long[] {null})field("static_name", Long[].class).equal(DSL.castNull(Long[].class)field("static_name", Long[].class).cast(String.class).eq(DSL.value("{null}")))field("static_name", Long[].class).cast(String.class).eq(DSL.value("'{null}'")))
any clue what am I doing wrong?
Note : I did try the query with plain sql and static_name = '{null}' worked