| I suppose the problem is that on JDBC level, the parameter values are passed with the `setObject(int index, Object o)` method. The PostgreSQL JDBC driver can't handle NULL values that way though so this is the problem you are having. When passing a NULL value for a parameter, this fails. One way around that is to cast the parameter to the desired type i.e. use ... where col = cast(:param as varchar) |