mirror of
https://github.com/postgres/postgres.git
synced 2025-12-12 02:37:31 +03:00
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:
@@ -72,6 +72,13 @@ SELECT '6' AS "One",
|
||||
6 | 6
|
||||
(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
|
||||
--
|
||||
|
||||
@@ -58,6 +58,9 @@ SELECT '6' AS "One",
|
||||
ELSE 7
|
||||
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
|
||||
--
|
||||
|
||||
Reference in New Issue
Block a user