Using concat(field1, field2) concatenates 0 instead of empty string (''
) if any of the fields is NULL
#36112
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
Feedback
Waiting on the submitter for answers
Describe the bug
How to Reproduce
Using concat(field1, field2) concatenates
0
instead of empty string (''
) if field2 is NULL.The field2 is integer.
For a
field1
of text type having valuetest
,field2
type integer and NULL (no value).A label using
concat(field1,field2)
expression returnstest0
instead of the expectedtest
(adds a0
instead of an empty string)I can expand the expression with an IF statement to solve it but.. it's a bug, right?
QGIS and OS versions
QGIS 3.10.5 Windows and Debian Bullseye
The text was updated successfully, but these errors were encountered: