Index: src/backend/tcop/postgres.c =================================================================== RCS file: /cvsroot/pgsql/src/backend/tcop/postgres.c,v retrieving revision 1.444 diff -c -c -r1.444 postgres.c *** src/backend/tcop/postgres.c 24 May 2005 04:18:04 -0000 1.444 --- src/backend/tcop/postgres.c 30 May 2005 19:37:09 -0000 *************** *** 498,504 **** if (IsA(parsetree, PrepareStmt)) parsetree = (Node *) (((PrepareStmt *) parsetree)->query); ! if (IsA(parsetree, SelectStmt)) continue; /* optimization for frequent command */ if (log_statement == LOGSTMT_MOD && --- 498,505 ---- 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 && *************** *** 514,519 **** --- 515,521 ---- if ((log_statement == LOGSTMT_MOD || log_statement == LOGSTMT_DDL) && (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 */