Browse Source

fix(api): include null values in `neq` filter

Signed-off-by: Pranav C <pranavxc@gmail.com>
pull/4861/head
Pranav C 2 years ago
parent
commit
928346e619
  1. 6
      packages/nocodb/src/lib/db/sql-data-mapper/lib/sql/conditionV2.ts

6
packages/nocodb/src/lib/db/sql-data-mapper/lib/sql/conditionV2.ts

@ -277,7 +277,11 @@ const parseConditionV2 = async (
break; break;
case 'neq': case 'neq':
case 'not': case 'not':
qb = qb.whereNot(field, val); qb = qb.where((nestedQb) => {
nestedQb
.whereNot(field, val)
.orWhereNotNull(customWhereClause ? _val : _field);
});
break; break;
case 'like': case 'like':
if (column.uidt === UITypes.Formula) { if (column.uidt === UITypes.Formula) {

Loading…
Cancel
Save