diff options
| author | Peter Eisentraut <peter_e@gmx.net> | 2017-03-22 15:26:59 -0400 |
|---|---|---|
| committer | Peter Eisentraut <peter_e@gmx.net> | 2017-03-22 15:27:40 -0400 |
| commit | cbf7ed51b8c0c3e506b91765769f76d5c2e1e9ac (patch) | |
| tree | 8e66e9b402dc2f2cdb430910fe86e30c73b6de19 /doc/src | |
| parent | b9418911900ff5b68a5457b1542668077664e897 (diff) | |
doc: Improve CREATE PUBLICATION examples
Diffstat (limited to 'doc/src')
| -rw-r--r-- | doc/src/sgml/ref/create_publication.sgml | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/doc/src/sgml/ref/create_publication.sgml b/doc/src/sgml/ref/create_publication.sgml index b00a91ef8a6..3cdde801fa1 100644 --- a/doc/src/sgml/ref/create_publication.sgml +++ b/doc/src/sgml/ref/create_publication.sgml @@ -163,7 +163,7 @@ CREATE PUBLICATION <replaceable class="parameter">name</replaceable> </para> <para> - <command>TRUNCATE</command> and other <acronym>DDL</acronym> operations + <command>TRUNCATE</command> and <acronym>DDL</acronym> operations are not published. </para> </refsect1> @@ -172,16 +172,25 @@ CREATE PUBLICATION <replaceable class="parameter">name</replaceable> <title>Examples</title> <para> - Create a simple publication that just publishes all DML for tables in it: + Create a publication that publishes all changes in two tables: <programlisting> -CREATE PUBLICATION mypublication; +CREATE PUBLICATION mypublication FOR TABLE users, departments; </programlisting> </para> <para> - Create an insert-only publication: + Create a publication that publishes all changes in all tables: <programlisting> -CREATE PUBLICATION insert_only WITH (NOPUBLISH UPDATE, NOPUBLISH DELETE); +CREATE PUBLICATION alltables FOR ALL TABLES; +</programlisting> + </para> + + <para> + Create a publication that only publishes <command>INSERT</command> + operations in one table: +<programlisting> +CREATE PUBLICATION insert_only FOR TABLE mydata + WITH (NOPUBLISH UPDATE, NOPUBLISH DELETE); </programlisting> </para> </refsect1> |
