-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #52992 from rafiss/backport19.2-52940
release-19.2: sql: allow DEALLOCATE ALL with a prepared statement
- Loading branch information
Showing
2 changed files
with
52 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
# deallocate_test checks that we can run DEALLOCATE ALL using a prepared | ||
# statement. See #52915. | ||
send | ||
Query {"String": "DROP TABLE IF EXISTS deallocate_test"} | ||
---- | ||
|
||
until ignore=NoticeResponse | ||
ReadyForQuery | ||
---- | ||
{"Type":"CommandComplete","CommandTag":"DROP TABLE"} | ||
{"Type":"ReadyForQuery","TxStatus":"I"} | ||
|
||
send | ||
Query {"String": "CREATE TABLE deallocate_test (a INT)"} | ||
---- | ||
|
||
until | ||
ReadyForQuery | ||
---- | ||
{"Type":"CommandComplete","CommandTag":"CREATE TABLE"} | ||
{"Type":"ReadyForQuery","TxStatus":"I"} | ||
|
||
# 80 = ASCII 'P' for Portal | ||
send | ||
Parse {"Name": "s1", "Query": "DEALLOCATE ALL"} | ||
Bind {"DestinationPortal": "p1", "PreparedStatement": "s1"} | ||
Execute {"Portal": "p1"} | ||
Sync | ||
---- | ||
|
||
until | ||
ReadyForQuery | ||
---- | ||
{"Type":"ParseComplete"} | ||
{"Type":"BindComplete"} | ||
{"Type":"CommandComplete","CommandTag":"DEALLOCATE ALL"} | ||
{"Type":"ReadyForQuery","TxStatus":"I"} | ||
|
||
send | ||
Query {"String": "DISCARD ALL"} | ||
---- | ||
|
||
until | ||
ReadyForQuery | ||
---- | ||
{"Type":"CommandComplete","CommandTag":"DISCARD"} | ||
{"Type":"ReadyForQuery","TxStatus":"I"} |