Synchronize doc/ copies of src/test/examples/.
authorNoah Misch
Fri, 23 Feb 2018 19:24:04 +0000 (11:24 -0800)
committerNoah Misch
Fri, 23 Feb 2018 19:24:08 +0000 (11:24 -0800)
This is mostly cosmetic, but it might fix build failures, on some
platform, when copying from the documentation.

Back-patch to 9.3 (all supported versions).

doc/src/sgml/libpq.sgml
src/test/examples/testlibpq2.sql

index 55efa249135cfa12cd1c7e8d061cc687f00d3908..d8dd28d04f7e9a091ab1429ac597bd35a8da0c25 100644 (file)
@@ -8015,13 +8015,16 @@ testlibpq.o(.text+0xa4): undefined reference to `PQerrorMessage'
 
 
 /*
+ * src/test/examples/testlibpq.c
+ *
+ *
  * testlibpq.c
  *
  *      Test the C version of libpq, the PostgreSQL frontend library.
  */
 #include 
 #include 
-#include 
+#include "libpq-fe.h"
 
 static void
 exit_nicely(PGconn *conn)
@@ -8142,6 +8145,9 @@ main(int argc, char **argv)
 
 
 /*
+ * src/test/examples/testlibpq2.c
+ *
+ *
  * testlibpq2.c
  *      Test of the asynchronous notification interface
  *
@@ -8174,6 +8180,10 @@ main(int argc, char **argv)
 #include 
 #include 
 #include 
+#ifdef HAVE_SYS_SELECT_H
+#include 
+#endif
+
 #include "libpq-fe.h"
 
 static void
@@ -8285,6 +8295,9 @@ main(int argc, char **argv)
 
 
 /*
+ * src/test/examples/testlibpq3.c
+ *
+ *
  * testlibpq3.c
  *      Test out-of-line parameters and binary I/O.
  *
index fb7d3535073500b1179ae4924768153effc8600f..1686c3ed0dfff0c19f21ce599405f6ba6fabb039 100644 (file)
@@ -3,4 +3,4 @@ CREATE TABLE TBL1 (i int4);
 CREATE TABLE TBL2 (i int4);
 
 CREATE RULE r1 AS ON INSERT TO TBL1 DO
-(INSERT INTO TBL2 VALUES (new.i); NOTIFY TBL2);
+  (INSERT INTO TBL2 VALUES (new.i); NOTIFY TBL2);