File tree 1 file changed +8
-6
lines changed 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -496,12 +496,14 @@ CREATE SUBSCRIPTION <replaceable class="parameter">subscription_name</replaceabl
496
496
other subscriptions created on the publisher) try this SQL query:
497
497
<programlisting>
498
498
# substitute <pub-names> below with your publication name(s) to be queried
499
- SELECT DISTINCT N.nspname AS schemaname, C.relname AS tablename
500
- FROM pg_publication P,
501
- LATERAL pg_get_publication_tables(P.pubname) GPT
502
- JOIN pg_subscription_rel PS ON (GPT.relid = PS.srrelid),
503
- pg_class C JOIN pg_namespace N ON (N.oid = C.relnamespace)
504
- WHERE C.oid = GPT.relid AND P.pubname IN (<pub-names>);
499
+ SELECT DISTINCT PT.schemaname, PT.tablename
500
+ FROM pg_publication_tables PT,
501
+ pg_subscription_rel PS
502
+ JOIN pg_class C ON (C.oid = PS.srrelid)
503
+ JOIN pg_namespace N ON (N.oid = C.relnamespace)
504
+ WHERE N.nspname = PT.schemaname AND
505
+ C.relname = PT.tablename AND
506
+ PT.pubname IN (<pub-names>);
505
507
</programlisting></para>
506
508
507
509
</refsect1>
You can’t perform that action at this time.
0 commit comments