Bug report #13204

Rule-base styles bug

Added by Mikhail Goloborodov over 9 years ago. Updated over 8 years ago.

Status:Closed
Priority:High
Assignee:Nathan Woodrow
Category:Expressions
Affected QGIS version:master Regression?:No
Operating System: Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:No Copied to github as #:21265

Description

In rule-based style expression string '1.1' is equal to string '1.10' or '1.10000' and so on.
So expression ('1.1' = '1.10') or ('1.1' IS '1.10') returns TRUE. It is absolutely inadmissible.

Associated revisions

Revision 8a2e8715
Added by Nyall Dawson over 8 years ago

Always use string comparison in expressions for string fields

Fixes #13204

Revision be8e4f96
Added by Nyall Dawson over 8 years ago

Always use string comparison in expressions for string fields

Fixes #13204

(cherry-picked from 8a2e8715fb3ffa21ecbd3d38310b04257029f656)

History

#1 Updated by Nathan Woodrow over 9 years ago

  • Target version set to Version 2.12
  • Category set to Expressions

#2 Updated by Nathan Woodrow over 9 years ago

  • Assignee set to Nathan Woodrow

Seems to be casting both sides to double if they both look like a double. I will have a look into it at some stage soon.

#3 Updated by Giovanni Manghi about 9 years ago

  • Target version deleted (Version 2.12)

#4 Updated by Nyall Dawson over 8 years ago

  • Status changed from Open to Closed

Also available in: Atom PDF