Add pgpool_recovery--1.1--1.2.sql file to update pgpool_recovery() function version.
authorBo Peng <pengbo@sraoss.co.jp>
Tue, 18 Sep 2018 03:27:45 +0000 (12:27 +0900)
committerBo Peng <pengbo@sraoss.co.jp>
Tue, 18 Sep 2018 03:27:45 +0000 (12:27 +0900)
src/Makefile.in
src/sql/pgpool-recovery/Makefile
src/sql/pgpool-recovery/pgpool_recovery--1.1--1.2.sql [new file with mode: 0644]

index 5f344771323082f81993567f72d126c6ef9856b8..f70b4593cf8f90b04ba4ef36cf2e50ccf30e5d2b 100644 (file)
@@ -517,6 +517,7 @@ EXTRA_DIST = sample/pgpool.pam \
                sql/pgpool-recovery/pgpool-recovery.sql.in \
                sql/pgpool-recovery/uninstall_pgpool-recovery.sql \
                sql/pgpool-recovery/pgpool_recovery--1.2.sql \
+               sql/pgpool-recovery/pgpool_recovery--1.1--1.2.sql \
                sql/pgpool-recovery/pgpool_recovery--1.1.sql \
                sql/pgpool-recovery/pgpool_recovery.control \
                sql/pgpool-recovery/Makefile \
index 63b7812ea2245cb582d429205e05c6ca750a17bd..510853ee72ab9fdb18144d2b9cadada13386492d 100644 (file)
@@ -3,7 +3,7 @@ DATA_built = pgpool-recovery.sql
 DATA = uninstall_pgpool-recovery.sql
 
 EXTENSION = pgpool_recovery
-DATA = pgpool_recovery--1.2.sql
+DATA = pgpool_recovery--1.2.sql pgpool_recovery--1.1--1.2.sql
 
 # if you are using PostgreSQL 8.0 or later,
 # using pg_config is recommended.
diff --git a/src/sql/pgpool-recovery/pgpool_recovery--1.1--1.2.sql b/src/sql/pgpool-recovery/pgpool_recovery--1.1--1.2.sql
new file mode 100644 (file)
index 0000000..cc55061
--- /dev/null
@@ -0,0 +1,9 @@
+/* contrib/pgpool_recovery/pgpool_recovery--1.1--1.2.sql */
+
+-- complain if script is sourced in psql, rather than via ALTER EXTENSION
+\echo Use "ALTER EXTENSION pgpool_recovery UPDATE TO '1.2'" to load this file. \quit
+
+create FUNCTION pgpool_recovery(script_name text, remote_host text, remote_data_directory text, remote_port text, recovery_node integer)
+RETURNS bool
+AS 'MODULE_PATHNAME', 'pgpool_recovery'
+LANGUAGE C STRICT;