diff -U3 /tmp/cirrus-ci-build/contrib/dblink/expected/dblink.out /tmp/cirrus-ci-build/build/testrun/dblink/regress/results/dblink.out --- /tmp/cirrus-ci-build/contrib/dblink/expected/dblink.out 2024-03-26 23:35:26.123871000 +0000 +++ /tmp/cirrus-ci-build/build/testrun/dblink/regress/results/dblink.out 2024-03-26 23:53:26.136742000 +0000 @@ -34,6 +34,7 @@ -- list the primary key fields SELECT * FROM dblink_get_pkey('foo'); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree position | colname ----------+--------- 1 | f1 @@ -88,6 +89,7 @@ -- list the primary key fields SELECT * FROM dblink_get_pkey('foo_1'); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree position | colname ----------+--------- 1 | f1 @@ -134,6 +136,7 @@ -- list the primary key fields SELECT * FROM dblink_get_pkey('"MySchema"."Foo"'); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree position | colname ----------+--------- 1 | f1 @@ -170,6 +173,7 @@ SELECT * FROM dblink(connection_parameters(),'SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE t.a > 7; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ---+---+------------ 8 | i | {a8,b8,c8} @@ -180,6 +184,7 @@ SELECT * FROM dblink('SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE t.a > 7; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree ERROR: connection not available -- The first-level connection's backend will crash on exit given OpenLDAP -- [2.4.24, 2.4.31]. We won't see evidence of any crash until the victim @@ -208,6 +213,17 @@ IF NOT detail LIKE 'syntax error in service file%' THEN RAISE; END IF; END $pl$; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree +CONTEXT: SQL statement "SELECT wait_pid(crash_pid) + FROM dblink(connection_parameters(), $$ + SELECT pg_backend_pid() FROM dblink( + 'service=test_ldap '||connection_parameters(), + -- This string concatenation is a hack to shoehorn a + -- set_pgservicefile call into the SQL statement. + 'SELECT 1' || set_pgservicefile('pg_service.conf') + ) t(c int) + $$) AS t(crash_pid int)" +PL/pgSQL function inline_code_block line 5 at PERFORM -- create a persistent connection SELECT dblink_connect(connection_parameters()); dblink_connect @@ -219,6 +235,7 @@ SELECT * FROM dblink('SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE t.a > 7; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ---+---+------------ 8 | i | {a8,b8,c8} @@ -265,6 +282,7 @@ -- fetch some data SELECT * FROM dblink_fetch('rmt_foo_cursor',4) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ---+---+------------ 0 | a | {a0,b0,c0} @@ -275,6 +293,7 @@ SELECT * FROM dblink_fetch('rmt_foo_cursor',4) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ---+---+------------ 4 | e | {a4,b4,c4} @@ -286,6 +305,7 @@ -- this one only finds two rows left SELECT * FROM dblink_fetch('rmt_foo_cursor',4) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ---+---+------------ 8 | i | {a8,b8,c8} @@ -295,6 +315,7 @@ -- intentionally botch a fetch SELECT * FROM dblink_fetch('rmt_foobar_cursor',4,false) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree NOTICE: cursor "rmt_foobar_cursor" does not exist CONTEXT: while fetching from cursor "rmt_foobar_cursor" on unnamed dblink connection a | b | c @@ -320,11 +341,13 @@ -- should generate 'cursor "rmt_foo_cursor" not found' error SELECT * FROM dblink_fetch('rmt_foo_cursor',4) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree ERROR: cursor "rmt_foo_cursor" does not exist CONTEXT: while fetching from cursor "rmt_foo_cursor" on unnamed dblink connection -- this time, 'cursor "rmt_foo_cursor" not found' as a notice SELECT * FROM dblink_fetch('rmt_foo_cursor',4,false) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree NOTICE: cursor "rmt_foo_cursor" does not exist CONTEXT: while fetching from cursor "rmt_foo_cursor" on unnamed dblink connection a | b | c @@ -342,6 +365,7 @@ SELECT * FROM dblink('SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE t.a > 7; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree ERROR: connection not available -- put more data into our table, first using arbitrary connection syntax -- but truncate the actual return value so we can use diff to check for success @@ -369,6 +393,7 @@ -- let's see it SELECT * FROM dblink('SELECT * FROM foo') AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ----+---+--------------- 0 | a | {a0,b0,c0} @@ -388,6 +413,7 @@ -- bad remote select SELECT * FROM dblink('SELECT * FROM foobar',false) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree NOTICE: relation "foobar" does not exist CONTEXT: while executing query on unnamed dblink connection a | b | c @@ -405,6 +431,7 @@ SELECT * FROM dblink('SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE a = 11; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ----+---+--------------- 11 | l | {a11,b99,c11} @@ -430,6 +457,7 @@ SELECT * FROM dblink('SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE a = 11; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ---+---+--- (0 rows) @@ -448,6 +476,7 @@ SELECT * FROM dblink('myconn','SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE t.a > 7; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree ERROR: could not establish connection DETAIL: missing "=" after "myconn" in connection info string -- create a named persistent connection @@ -461,6 +490,7 @@ SELECT * FROM dblink('myconn','SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE t.a > 7; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ----+---+--------------- 8 | i | {a8,b8,c8} @@ -472,6 +502,7 @@ SELECT * FROM dblink('myconn','SELECT * FROM foobar',false) AS t(a int, b text, c text[]) WHERE t.a > 7; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree NOTICE: relation "foobar" does not exist CONTEXT: while executing query on dblink connection named "myconn" a | b | c @@ -493,6 +524,7 @@ SELECT * FROM dblink('myconn2','SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE t.a > 7; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ----+---+--------------- 8 | i | {a8,b8,c8} @@ -614,6 +646,7 @@ -- fetch some data SELECT * FROM dblink_fetch('myconn','rmt_foo_cursor',4) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ---+---+------------ 0 | a | {a0,b0,c0} @@ -624,6 +657,7 @@ SELECT * FROM dblink_fetch('myconn','rmt_foo_cursor',4) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ---+---+------------ 4 | e | {a4,b4,c4} @@ -635,6 +669,7 @@ -- this one only finds three rows left SELECT * FROM dblink_fetch('myconn','rmt_foo_cursor',4) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ----+---+--------------- 8 | i | {a8,b8,c8} @@ -645,6 +680,7 @@ -- fetch some data incorrectly SELECT * FROM dblink_fetch('myconn','rmt_foobar_cursor',4,false) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree NOTICE: cursor "rmt_foobar_cursor" does not exist CONTEXT: while fetching from cursor "rmt_foobar_cursor" on dblink connection named "myconn" a | b | c @@ -661,6 +697,7 @@ -- should generate 'cursor "rmt_foo_cursor" not found' error SELECT * FROM dblink_fetch('myconn','rmt_foo_cursor',4) AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree ERROR: cursor "rmt_foo_cursor" does not exist CONTEXT: while fetching from cursor "rmt_foo_cursor" on dblink connection named "myconn" -- close the named persistent connection @@ -674,6 +711,7 @@ SELECT * FROM dblink('myconn','SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE t.a > 7; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree ERROR: could not establish connection DETAIL: missing "=" after "myconn" in connection info string -- create a named persistent connection @@ -694,6 +732,7 @@ -- let's see it SELECT * FROM dblink('myconn','SELECT * FROM foo') AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ----+---+--------------- 0 | a | {a0,b0,c0} @@ -721,6 +760,7 @@ SELECT * FROM dblink('myconn','SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE a = 11; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ----+---+--------------- 11 | l | {a11,b99,c11} @@ -737,6 +777,7 @@ SELECT * FROM dblink('myconn','SELECT * FROM foo') AS t(a int, b text, c text[]) WHERE a = 11; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ---+---+--- (0 rows) @@ -761,6 +802,7 @@ SELECT * from dblink_send_query('dtest1', 'select * from foo where f1 < 3') as t1; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree t1 ---- 1 @@ -774,6 +816,7 @@ SELECT * from dblink_send_query('dtest2', 'select * from foo where f1 > 2 and f1 < 7') as t1; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree t1 ---- 1 @@ -787,6 +830,7 @@ SELECT * from dblink_send_query('dtest3', 'select * from foo where f1 > 6') as t1; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree t1 ---- 1 @@ -799,6 +843,7 @@ UNION (SELECT * from dblink_get_result('dtest3') as t3(f1 int, f2 text, f3 text[])) ORDER by f1; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree -- dblink_get_connections returns an array with elements in a machine-dependent -- ordering, so we must resort to unnesting and sorting for a stable result create function unnest(anyarray) returns setof anyelement @@ -806,6 +851,7 @@ select $1[i] from generate_series(array_lower($1,1), array_upper($1,1)) as i $$; SELECT * FROM unnest(dblink_get_connections()) ORDER BY 1; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree unnest -------- dtest1 @@ -861,6 +907,7 @@ SELECT * from dblink_send_query('dtest1', 'select * from foo where f1 < 3') as t1; +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree t1 ---- 1 @@ -913,6 +960,7 @@ (1 row) SELECT * FROM dblink('myconn','SELECT * FROM foo') AS t(a int, b text, c text[]); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a | b | c ----+---+--------------- 0 | a | {a0,b0,c0} @@ -991,6 +1039,7 @@ (1 row) SELECT notify_name, be_pid = (select t.be_pid from dblink('select pg_backend_pid()') as t(be_pid int)) AS is_self_notify, extra from dblink_get_notify(); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree notify_name | is_self_notify | extra -------------+----------------+------- regression | t | @@ -998,6 +1047,7 @@ (2 rows) SELECT * from dblink_get_notify(); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree notify_name | be_pid | extra -------------+--------+------- (0 rows) @@ -1064,6 +1114,7 @@ FROM dblink('myconn', 'SELECT * FROM (VALUES (''12.03.2013 00:00:00+00'')) t') AS t(a timestamptz); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a ------------------------ 2013-03-12 00:00:00+00 @@ -1076,6 +1127,7 @@ (VALUES (''12.03.2013 00:00:00+00''), (''12.03.2013 00:00:00+00'')) t') AS t(a timestamptz); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree a ------------------------ 2013-03-12 00:00:00+00 @@ -1087,6 +1139,7 @@ FROM dblink_send_query('myconn', 'SELECT * FROM (VALUES (''12.03.2013 00:00:00+00'')) t'); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree dblink_send_query ------------------- 1 @@ -1096,6 +1149,7 @@ (SELECT * from dblink_get_result('myconn') as t(t timestamptz)) UNION ALL (SELECT * from dblink_get_result('myconn') as t(t timestamptz)); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree SELECT * FROM result; t ------------------------ @@ -1109,6 +1163,7 @@ 'SELECT * FROM (VALUES (''12.03.2013 00:00:00+00''), (''12.03.2013 00:00:00+00'')) t'); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree dblink_send_query ------------------- 1 @@ -1120,6 +1175,7 @@ (SELECT * from dblink_get_result('myconn') as t(t timestamptz)) UNION ALL (SELECT * from dblink_get_result('myconn') as t(t timestamptz)); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree SELECT * FROM result; t ------------------------ @@ -1139,6 +1195,7 @@ FROM dblink('myconn', 'SELECT * FROM (VALUES (''-1 2:03:04'')) i') AS i(i interval); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree i ------------------- -1 days -02:03:04 @@ -1158,6 +1215,7 @@ FROM dblink('myconn', 'SELECT * FROM (VALUES (''03.12.2013 00:00:00+00'')) t') AS t(a timestamptz); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree SELECT dblink_exec('myconn', 'SET datestyle = GERMAN, DMY;'); dblink_exec ------------- @@ -1169,6 +1227,7 @@ FROM dblink('myconn', 'SELECT * FROM (VALUES (''12.03.2013 00:00:00+00'')) t') AS t(a timestamptz); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree SELECT * FROM result; t ------------------------ @@ -1187,6 +1246,7 @@ SELECT * FROM dblink_fetch('myconn','error_cursor', 1) AS t(i int); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree i --- 1 @@ -1194,6 +1254,7 @@ SELECT * FROM dblink_fetch('myconn','error_cursor', 1) AS t(i int); +WARNING: outfuncs/readfuncs failed to produce an equal rewritten parse tree ERROR: invalid input syntax for type integer: "not an int" -- Make sure that the local settings have retained their values in spite -- of shenanigans on the connection.