This is an automated email from the ASF dual-hosted git repository.

oppenheimer01 pushed a commit to branch cbdb-postgres-merge
in repository https://gitbox.apache.org/repos/asf/cloudberry.git

commit 5e3da1a385113ac2c3681bc49c82fbed124e1fe9
Author: Jinbao Chen <[email protected]>
AuthorDate: Fri Apr 24 12:46:29 2026 -0400

    Fix some answer files
---
 .../output/parallel_retrieve_cursor/explain.source    | 19 ++++++++-----------
 src/test/regress/expected/partition_append.out        | 18 +++++++++++-------
 src/test/regress/sql/partition_append.sql             |  4 ++++
 3 files changed, 23 insertions(+), 18 deletions(-)

diff --git a/src/test/isolation2/output/parallel_retrieve_cursor/explain.source 
b/src/test/isolation2/output/parallel_retrieve_cursor/explain.source
index 15baecb724f..aa2c65ac65b 100644
--- a/src/test/isolation2/output/parallel_retrieve_cursor/explain.source
+++ b/src/test/isolation2/output/parallel_retrieve_cursor/explain.source
@@ -129,17 +129,14 @@ EXPLAIN (VERBOSE, COSTS false) DECLARE c1 PARALLEL 
RETRIEVE CURSOR FOR SELECT *
  Optimizer: Postgres query optimizer                                           
                                                                                
                                                                                
                                                                                
                                                                                
                                                   
 (5 rows)
 EXPLAIN (VERBOSE, COSTS false) DECLARE c1 PARALLEL RETRIEVE CURSOR FOR SELECT 
* FROM pg_class ORDER BY relname;
- QUERY PLAN                                                                    
                                                                                
                                                                                
                                                                                
                                                                                
                                 
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
- Sort                                                                          
                                                                                
                                                                                
                                                                                
                                                                                
                                 
-   Output: oid, relname, relnamespace, reltype, reloftype, relowner, relam, 
relfilenode, reltablespace, relpages, reltuples, relallvisible, reltoastrelid, 
relhasindex, relisshared, relpersistence, relkind, relnatts, relchecks, 
relhasrules, relhastriggers, relhassubclass, relrowsecurity, 
relforcerowsecurity, relispopulated, relreplident, relispartition, relisivm, 
relisdynamic, relmvrefcount, relrewrite, relfrozenxid, relminmxid, relacl, 
reloptions, relpartbound
-   Sort Key: pg_class.relname                                                  
                                                                                
                                                                                
                                                                                
                                                                                
                                 
-   ->  Seq Scan on pg_catalog.pg_class                                         
                                                                                
                                                                                
                                                                                
                                                                                
                                 
-         Output: oid, relname, relnamespace, reltype, reloftype, relowner, 
relam, relfilenode, reltablespace, relpages, reltuples, relallvisible, 
reltoastrelid, relhasindex, relisshared, relpersistence, relkind, relnatts, 
relchecks, relhasrules, relhastriggers, relhassubclass, relrowsecurity, 
relforcerowsecurity, relispopulated, relreplident, relispartition, relisivm, 
relisdynamic, relmvrefcount, relrewrite, relfrozenxid, relminmxid, relacl, 
reloptions, relpartbound
- Settings: enable_incremental_sort = 'on'                                      
                                                                                
                                                                                
                                                                                
                                                                                
                                 
- Endpoint: "on coordinator"                                                    
                                                                                
                                                                                
                                                                                
                                                                                
                                 
- Optimizer: Postgres query optimizer                                           
                                                                                
                                                                                
                                                                                
                                                                                
                                 
-(8 rows)
+ QUERY PLAN                                                                    
                                                                                
                                                                                
                                                                                
                                                                                
                                                                  
+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
+ Index Scan using pg_class_relname_nsp_index on pg_catalog.pg_class            
                                                                                
                                                                                
                                                                                
                                                                                
                                                                  
+   Output: oid, relname, relnamespace, reltype, reloftype, relowner, relam, 
relfilenode, reltablespace, relpages, reltuples, relallvisible, reltoastrelid, 
relhasindex, relisshared, relpersistence, relkind, relnatts, relchecks, 
relhasrules, relhastriggers, relhassubclass, relrowsecurity, 
relforcerowsecurity, relispopulated, relreplident, relispartition, relisivm, 
relisdynamic, relmvrefcount, relrewrite, relfrozenxid, relminmxid, relacl, 
reloptions, relpartbound 
+ Settings: optimizer = 'off', enable_incremental_sort = 'on'                   
                                                                                
                                                                                
                                                                                
                                                                                
                                                                  
+ Endpoint: "on coordinator"                                                    
                                                                                
                                                                                
                                                                                
                                                                                
                                                                  
+ Optimizer: Postgres query optimizer                                           
                                                                                
                                                                                
                                                                                
                                                                                
                                                                  
+(5 rows)
 EXPLAIN (VERBOSE, COSTS false) DECLARE c1 PARALLEL RETRIEVE CURSOR FOR SELECT 
* FROM pg_class WHERE gp_segment_id=1;
  QUERY PLAN                                                                    
                                                                                
                                                                                
                                                                                
                                                                                
                                     
 
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
diff --git a/src/test/regress/expected/partition_append.out 
b/src/test/regress/expected/partition_append.out
index fff341d680a..9154c7d5a6b 100755
--- a/src/test/regress/expected/partition_append.out
+++ b/src/test/regress/expected/partition_append.out
@@ -161,6 +161,7 @@ ERROR:  child table is missing column "b"
 -- different owner 
 create role part_role_append;
 NOTICE:  resource queue required -- using default resource queue "pg_default"
+GRANT CREATE ON SCHEMA public TO part_role_append;
 create table bar_p (i int, j int) distributed by (i);
 set session authorization part_role_append;
 -- should fail
@@ -196,6 +197,7 @@ alter table foo_p split partition for (1) at (2) into 
(partition prt_11, partiti
 (4 rows)
 
 drop table foo_p;
+REVOKE CREATE ON SCHEMA public FROM part_role_append;
 drop role part_role_append;
 -- WITH OIDS is no longer supported. Check that it't rejected with the GPDB
 -- partitioning syntax, too.
@@ -5726,6 +5728,13 @@ select relname, relkind from pg_class where relkind in 
('r', 'p') and relname li
 select gp_segment_id, relname, relkind from gp_dist_random('pg_class') where 
relkind in ('r', 'p') and relname like 'sales%' and relfrozenxid=0;
  gp_segment_id |          relname           | relkind 
 ---------------+----------------------------+---------
+             2 | sales                      | p
+             2 | sales                      | p
+             2 | sales_1_prt_2              | p
+             2 | sales_1_prt_3              | p
+             2 | sales_1_prt_4              | p
+             2 | sales_1_prt_5              | p
+             2 | sales_1_prt_outlying_dates | p
              0 | sales                      | p
              0 | sales                      | p
              0 | sales_1_prt_2              | p
@@ -5740,13 +5749,6 @@ select gp_segment_id, relname, relkind from 
gp_dist_random('pg_class') where rel
              1 | sales_1_prt_4              | p
              1 | sales_1_prt_5              | p
              1 | sales_1_prt_outlying_dates | p
-             2 | sales                      | p
-             2 | sales                      | p
-             2 | sales_1_prt_2              | p
-             2 | sales_1_prt_3              | p
-             2 | sales_1_prt_4              | p
-             2 | sales_1_prt_5              | p
-             2 | sales_1_prt_outlying_dates | p
 (21 rows)
 
 alter table sales drop column tax;
@@ -6176,6 +6178,7 @@ DROP TABLE unexpanded_attach2;
 -- set owner for partition root (should be inherited except for ATTACH, 
EXCHANGE)
 CREATE ROLE part_inherit_role CREATEROLE;
 NOTICE:  resource queue required -- using default resource queue "pg_default"
+GRANT CREATE ON SCHEMA public TO part_inherit_role;
 CREATE ROLE part_inherit_other_role IN ROLE part_inherit_role;
 NOTICE:  resource queue required -- using default resource queue "pg_default"
 CREATE ROLE part_inherit_priv_role;
@@ -6438,6 +6441,7 @@ RESET ROLE;
 DROP TABLE part_inherit;
 DROP FUNCTION part_inherit_trig CASCADE;
 DROP TABLE part_inherit_exchange_out;
+REVOKE CREATE ON SCHEMA public FROM part_inherit_role;
 DROP ROLE part_inherit_role;
 DROP ROLE part_inherit_other_role;
 DROP ROLE part_inherit_priv_role;
diff --git a/src/test/regress/sql/partition_append.sql 
b/src/test/regress/sql/partition_append.sql
index 7cb3a3ba062..9a59e5c2862 100644
--- a/src/test/regress/sql/partition_append.sql
+++ b/src/test/regress/sql/partition_append.sql
@@ -117,6 +117,7 @@ ALTER TABLE two_level_pt ALTER PARTITION FOR (1)
 
 -- different owner 
 create role part_role_append;
+GRANT CREATE ON SCHEMA public TO part_role_append;
 create table bar_p (i int, j int) distributed by (i);
 set session authorization part_role_append;
 -- should fail
@@ -145,6 +146,7 @@ alter table foo_p split partition for (1) at (2) into 
(partition prt_11, partiti
 \dt foo_*
 drop table foo_p;
 
+REVOKE CREATE ON SCHEMA public FROM part_role_append;
 drop role part_role_append;
 
 -- WITH OIDS is no longer supported. Check that it't rejected with the GPDB
@@ -3888,6 +3890,7 @@ DROP TABLE unexpanded_attach2;
 --
 -- set owner for partition root (should be inherited except for ATTACH, 
EXCHANGE)
 CREATE ROLE part_inherit_role CREATEROLE;
+GRANT CREATE ON SCHEMA public TO part_inherit_role;
 CREATE ROLE part_inherit_other_role IN ROLE part_inherit_role;
 CREATE ROLE part_inherit_priv_role;
 CREATE ROLE part_inherit_attach_priv_role;
@@ -4090,6 +4093,7 @@ RESET ROLE;
 DROP TABLE part_inherit;
 DROP FUNCTION part_inherit_trig CASCADE;
 DROP TABLE part_inherit_exchange_out;
+REVOKE CREATE ON SCHEMA public FROM part_inherit_role;
 DROP ROLE part_inherit_role;
 DROP ROLE part_inherit_other_role;
 DROP ROLE part_inherit_priv_role;


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to