Fix PostgreSQL date diff pattern #668