IIF -> FALSE produces space #8377
Closed
tastyshrimps
announced in
Announcements
Replies: 3 comments 1 reply
-
By design. Resulting data type of |
Beta Was this translation helpful? Give feedback.
0 replies
-
If you cast literals to varchar() you will get desired behavior: SQL> SELECT 'X' || IIF(1=2, cast('X' as varchar(1)), cast('' as varchar(1))) || 'X' FROM RDB$DATABASE;
SQL> |
Beta Was this translation helpful? Give feedback.
1 reply
-
Makes sense. Thank you° |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
When an IIF resolves to FALSE, and only then, an empty string concatenation resolves to a space:
=> X X
Firebird 5.0.1
Classic Server
Beta Was this translation helpful? Give feedback.
All reactions