mirror of https://github.com/postgres/postgres
This trivial patch adds a regression test for CASE expressions that use
an untyped literal in the CASE's test expression. This adds test coverage for a bug that was fixed by Tom on January 12.
This commit is contained in:
parent
0d45116eb0
commit
48e2bb13c9
|
@ -72,6 +72,13 @@ SELECT '6' AS "One",
|
||||||
6 | 6
|
6 | 6
|
||||||
(1 row)
|
(1 row)
|
||||||
|
|
||||||
|
-- Test for cases involving untyped literals in test expression
|
||||||
|
SELECT CASE 'a' WHEN 'a' THEN 1 ELSE 2 END;
|
||||||
|
case
|
||||||
|
------
|
||||||
|
1
|
||||||
|
(1 row)
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Examples of targets involving tables
|
-- Examples of targets involving tables
|
||||||
--
|
--
|
||||||
|
|
|
@ -58,6 +58,9 @@ SELECT '6' AS "One",
|
||||||
ELSE 7
|
ELSE 7
|
||||||
END AS "Two WHEN with default";
|
END AS "Two WHEN with default";
|
||||||
|
|
||||||
|
-- Test for cases involving untyped literals in test expression
|
||||||
|
SELECT CASE 'a' WHEN 'a' THEN 1 ELSE 2 END;
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Examples of targets involving tables
|
-- Examples of targets involving tables
|
||||||
--
|
--
|
||||||
|
|
Loading…
Reference in New Issue