Hi,
The parameter defaultDueDate is a java.sql.Date object, an actual Date. When I run the query with the value in it, it works:
```sql
db=> select COALESCE(duedate, date '2017-02-01' + 1) from invoices order by duedate desc;
coalesce
---------------------
2017-02-02 00:00:00
2017-02-02 00:00:00
2016-11-14 00:00:00
2017-02-10 00:00:00
2017-02-02 00:00:00
2017-02-13 00:00:00
2017-02-02 00:00:00
2017-02-02 00:00:00
```
But when I send it as a parameter, it ignores it and seems to think the expression is of type interger.