diff --git a/packages/nocodb/src/db/conditionV2.ts b/packages/nocodb/src/db/conditionV2.ts index c50ca1dba1..5a990ab1b6 100644 --- a/packages/nocodb/src/db/conditionV2.ts +++ b/packages/nocodb/src/db/conditionV2.ts @@ -581,7 +581,15 @@ const parseConditionV2 = async ( qb = qb.where(knex.raw('BINARY ?? = ?', [field, val])); } } else { - qb = qb.where(field, val); + if(column.uidt === UITypes.DateTime) { + if(qb.client.config.client === 'pg') { + qb = qb.where(knex.raw('??::date = ?', [field, val])); + } else { + qb = qb.where(knex.raw('DATE(??) = DATE(?)', [field, val])); + } + } else { + qb = qb.where(field, val); + } } if (column.uidt === UITypes.Rating && val === 0) { // unset rating is considered as NULL