Index: src/backend/tcop/postgres.c =================================================================== RCS file: /cvsroot/pgsql/src/backend/tcop/postgres.c,v retrieving revision 1.440 diff -c -c -r1.440 postgres.c *** src/backend/tcop/postgres.c 31 Dec 2004 22:01:16 -0000 1.440 --- src/backend/tcop/postgres.c 1 Jun 2005 23:24:09 -0000 *************** *** 495,501 **** if (IsA(parsetree, PrepareStmt)) parsetree = (Node *) (((PrepareStmt *) parsetree)->query); ! if (IsA(parsetree, SelectStmt)) continue; /* optimization for frequent command */ if (log_statement == LOGSTMT_MOD && --- 495,502 ---- if (IsA(parsetree, PrepareStmt)) parsetree = (Node *) (((PrepareStmt *) parsetree)->query); ! if (IsA(parsetree, SelectStmt) && ! ((SelectStmt *) parsetree)->into == NULL) continue; /* optimization for frequent command */ if (log_statement == LOGSTMT_MOD && *************** *** 513,518 **** --- 514,520 ---- } commandTag = CreateCommandTag(parsetree); if (strncmp(commandTag, "CREATE ", strlen("CREATE ")) == 0 || + IsA(parsetree, SelectStmt) || /* SELECT INTO, CREATE AS */ strncmp(commandTag, "ALTER ", strlen("ALTER ")) == 0 || strncmp(commandTag, "DROP ", strlen("DROP ")) == 0 || IsA(parsetree, GrantStmt) || /* GRANT or REVOKE */