Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
10.15.2.0
-
None
-
None
-
Normal
-
Repro attached, Workaround attached
-
Deviation from standard
Description
While this parses just fine:
values( nullif( 1 = 0, exists(values(1)) ) );
This doesn't work:
values( coalesce( 1 = 0, exists(values(1)) ) );
Resulting in:
SQL Error [30000] [42X01]: Syntax error: Encountered "=" at line 3, column 7.
The workaround is to wrap both arguments in parentheses
values( coalesce( (1 = 0), (exists(values(1))) ) );
I don't think there's a good reason for this limitation, so I'm guessing it's a parser bug?