summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorItagaki Takahiro <itagaki.takahiro@gmail.com>2010-09-28 14:27:53 +0900
committerItagaki Takahiro <itagaki.takahiro@gmail.com>2010-09-28 14:27:53 +0900
commitb4f4d022b07ae162a29f36301a17e12da8011816 (patch)
tree40ee496a220da2d935449e7d15908f540eb80c47 /src
parenta824c59c184435184c8466be62fd6a6ba3dfd6a6 (diff)
Add DISCARD to the command_no_begin list for AUTOCOMMIT=off.
Backpatch to 8.3. Reported by Sergey Burladyan.
Diffstat (limited to 'src')
-rw-r--r--src/bin/psql/common.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/bin/psql/common.c b/src/bin/psql/common.c
index 72aad262f5a..0f83dd3c451 100644
--- a/src/bin/psql/common.c
+++ b/src/bin/psql/common.c
@@ -1352,6 +1352,9 @@ command_no_begin(const char *query)
return true;
}
+ if (wordlen == 7 && pg_strncasecmp(query, "discard", 7) == 0)
+ return true;
+
return false;
}