Is there a way to check collection is empty for variable arguments?
I have a filter query with default empty values, and for each param I check if it’s empty, like:
AND (:nameFilter = ‘’ OR LOCATE(:nameFilter, fullName) > 0)
And for a collection I’d like to use something like
AND (:field = () OR field in :field)
Which seems not valid SQL. I know that I can join this collection to string and use REGEXP, but maybe there’s an easier way?
Also if I try to compare with NULL, it generates some strange
Collection<Int?>
type.