Content-Length: 263113 | pFad | http://github.com/postgrespro/postgres_cluster/commit/530f8065243b185e56c70ab317a9b40964b4ad00

A0 Re-allow user_catalog_table option for materialized views. · postgrespro/postgres_cluster@530f806 · GitHub
Skip to content

Commit 530f806

Browse files
committed
Re-allow user_catalog_table option for materialized views.
The reloptions stuff allows this option to be set on a matview. While it's questionable whether that is useful or was really intended, it does work, and we shouldn't change that in minor releases. Commit e3e66d8 disabled the option since I didn't realize that it was possible for it to be set on a matview. Tweak the test to re-allow it. Discussion: <19749.1478711862@sss.pgh.pa.us>
1 parent 279c439 commit 530f806

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/include/utils/rel.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -270,8 +270,9 @@ typedef struct StdRdOptions
270270
* from the pov of logical decoding. Note multiple eval of argument!
271271
*/
272272
#define RelationIsUsedAsCatalogTable(relation) \
273-
((relation)->rd_rel->relkind == RELKIND_RELATION && \
274-
(relation)->rd_options ? \
273+
((relation)->rd_options && \
274+
((relation)->rd_rel->relkind == RELKIND_RELATION || \
275+
(relation)->rd_rel->relkind == RELKIND_MATVIEW) ? \
275276
((StdRdOptions *) (relation)->rd_options)->user_catalog_table : false)
276277

277278
/*

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/postgrespro/postgres_cluster/commit/530f8065243b185e56c70ab317a9b40964b4ad00

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy