Skip to content
Permalink
Browse files

Fix Virtual layers display with empty subsetstring

Fixes #19721

Virtual layers incorrectly show no feature when the expression filter string is empty, instead of correctly showing all the features.

Subset string needs to be tested against Empty instead of Null in order to correctly populate the wheres list and prepare a well formed SQL query string.
  • Loading branch information
agiudiceandrea authored and nyalldawson committed Aug 28, 2018
1 parent 65f4bf1 commit 99696b6ee10ea18a35a4cf23f8e506af69ee1f4e
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/providers/virtual/qgsvirtuallayerfeatureiterator.cpp
@@ -65,7 +65,7 @@ QgsVirtualLayerFeatureIterator::QgsVirtualLayerFeatureIterator( QgsVirtualLayerF
QStringList wheres;
QString offset;
QString subset = mSource->mSubset;
if ( !subset.isNull() )
if ( !subset.isEmpty() )
{
wheres << subset;
}

0 comments on commit 99696b6

Please sign in to comment.
You can’t perform that action at this time.