Skip to content

Commit

Permalink
[virtual] Fix xFilter for null value comparisons
Browse files Browse the repository at this point in the history
  • Loading branch information
Hugo Mercier committed Dec 2, 2016
1 parent 499ae31 commit e0e60da
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/providers/virtual/qgsvirtuallayersqlitemodule.cpp
Expand Up @@ -619,13 +619,13 @@ int vtableFilter( sqlite3_vtab_cursor * cursor, int idxNum, const char *idxStr,
expr += "'" + str.replace( "'", "''" ) + "'";
break;
}
default:
expr = "";
}
if ( !expr.isEmpty() )
{
request.setFilterExpression( expr );
case SQLITE_NULL:
case SQLITE_BLOB: // comparison to blob ignored
default:
expr += " is null";
break;
}
request.setFilterExpression( expr );
}
VTableCursor *c = reinterpret_cast<VTableCursor*>( cursor );
c->filter( request );
Expand Down

0 comments on commit e0e60da

Please sign in to comment.