pgpool2.git / summary / log / commit / refs
commit 778a8fff6a4efbac7e8ec36f9000115bf264bac4
Author: Tatsuo Ishii <ishii at sraoss.co.jp>
Date: Sat Mar 07 09:19:58 2009 +0000
Add a comment to need_insert_lock() if the query being used to check
if the table has SERIAL column is valid for PostgreSQL 7.3 to 8.3.
pool_process_query.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/pool_process_query.c b/pool_process_query.c
index 321d2b515..281216296 100644
--- a/pool_process_query.c
+++ b/pool_process_query.c
@@ -3031,6 +3031,10 @@ POOL_STATUS do_query(POOL_CONNECTION *backend, char *query, POOL_SELECT_RESULT *
*/
int need_insert_lock(POOL_CONNECTION_POOL *backend, char *query, Node *node)
{
+/*
+ * Query to know if the target table has SERIAL column or not.
+ * This query is valid through PostgreSQL 7.3 to 8.3.
+ */
#define NEXTVALQUERY "SELECT count(*) FROM pg_catalog.pg_attrdef AS d, pg_catalog.pg_class AS c WHERE d.adrelid = c.oid AND d.adsrc ~ 'nextval' AND c.relname = '%s'"
#define INSERT_STATEMENT_MAX_CACHE 16
[parent: 509e553b58f1]