summaryrefslogtreecommitdiff
path: root/src/test/regress/expected/subselect.out
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2022-01-16 16:39:26 -0500
committerTom Lane <tgl@sss.pgh.pa.us>2022-01-16 16:39:26 -0500
commit6478896675660402171c97d6307e6e1519250025 (patch)
tree1cc838e570e2c916ac8601609e6eb48f01f8b6d6 /src/test/regress/expected/subselect.out
parentfe75517443b7c38f5251d007d06321655ce6c0b6 (diff)
downloadpostgresql-6478896675660402171c97d6307e6e1519250025.tar.gz
Teach hash_ok_operator() that record_eq is only sometimes hashable.
The need for this was foreseen long ago, but when record_eq actually became hashable (in commit 01e658fa7), we missed updating this spot. Per bug #17363 from Elvis Pranskevichus. Back-patch to v14 where the faulty commit came in. Discussion: https://postgr.es/m/17363-f6d42fd0d726be02@postgresql.org
Diffstat (limited to 'src/test/regress/expected/subselect.out')
-rw-r--r--src/test/regress/expected/subselect.out23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/test/regress/expected/subselect.out b/src/test/regress/expected/subselect.out
index 4e8ddc7061..45c75eecc5 100644
--- a/src/test/regress/expected/subselect.out
+++ b/src/test/regress/expected/subselect.out
@@ -790,6 +790,29 @@ select 'foo'::text in (select 'bar'::name union all select 'bar'::name);
(1 row)
--
+-- Test that we don't try to hash nested records (bug #17363)
+-- (Hashing could be supported, but for now we don't)
+--
+explain (verbose, costs off)
+select row(row(row(1))) = any (select row(row(1)));
+ QUERY PLAN
+-------------------------------------------
+ Result
+ Output: (SubPlan 1)
+ SubPlan 1
+ -> Materialize
+ Output: '("(1)")'::record
+ -> Result
+ Output: '("(1)")'::record
+(7 rows)
+
+select row(row(row(1))) = any (select row(row(1)));
+ ?column?
+----------
+ t
+(1 row)
+
+--
-- Test case for premature memory release during hashing of subplan output
--
select '1'::text in (select '1'::name union all select '1'::name);