Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NULL Strings in Mif files don't interact well with expressions (regression) #22463

Closed
qgib opened this issue Mar 14, 2016 · 1 comment
Closed
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Expressions Related to the QGIS expression engine or specific expression functions
Milestone

Comments

@qgib
Copy link
Contributor

qgib commented Mar 14, 2016

Author Name: Ian Turton (@ianturton)
Original Redmine Issue: 14487
Affected QGIS version: 2.14.0
Redmine category:expressions


I have a mif file that is used in training and prior to 2.14 we would select polygons with no name by using

"name" is NOT NULL 

in the expression builder. In 2.14 this now selects all the features including the 23 with empty/null names. You also can't do a work round like

length("name") = 0 

as none of the features match.

Saving the data as a Shapefile makes everything work as expected.

I've attached the mif/mid files.


@qgib
Copy link
Contributor Author

qgib commented Mar 14, 2016

Author Name: Nyall Dawson (@nyalldawson)


Looking at this - there's no NULL names in the file. There's names which are empty strings, but that's different to null.

length("name") > 0 works for me, it selects 147 features
similarly
"name" <> '' also works (selects same 147 features)

I'm not sure why this would have worked in earlier versions (perhaps it was a change in the underlying GDAL library), but there's no reproducable bug here.


  • resolution was changed from to invalid
  • status_id was changed from Open to Closed

@qgib qgib added Bug Either a bug report, or a bug fix. Let's hope for the latter! Expressions Related to the QGIS expression engine or specific expression functions labels May 25, 2019
@qgib qgib added this to the Version 2.14 milestone May 25, 2019
@qgib qgib closed this as completed May 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Expressions Related to the QGIS expression engine or specific expression functions
Projects
None yet
Development

No branches or pull requests

1 participant