diff options
author | Pallavi Sontakke | 2016-07-27 09:51:39 +0000 |
---|---|---|
committer | Pallavi Sontakke | 2016-07-27 09:51:39 +0000 |
commit | 056b34a365c61f752d6fc22d6fb99c0b08110097 (patch) | |
tree | 93164a48609e8c2c024c69d47421324160554428 | |
parent | e2db6c20bd5039f797574dc454cbe974674f8334 (diff) |
Add test case for Issue #74
SQL error codes are not correctly sent back to
the client when dealing with error on COPY protocol
-rw-r--r-- | src/test/regress/expected/xl_reported_bugs.out | 11 | ||||
-rw-r--r-- | src/test/regress/sql/xl_reported_bugs.sql | 14 |
2 files changed, 25 insertions, 0 deletions
diff --git a/src/test/regress/expected/xl_reported_bugs.out b/src/test/regress/expected/xl_reported_bugs.out index 33b8daecbc..7218b26c73 100644 --- a/src/test/regress/expected/xl_reported_bugs.out +++ b/src/test/regress/expected/xl_reported_bugs.out @@ -1,3 +1,14 @@ +-- #74 +-- SQL error codes are not correctly sent back to the client when dealing with error on COPY protocol +\set VERBOSITY verbose +create table copytbl(a integer, b text default 'a_copytbl', primary key (a)); +insert into copytbl select generate_series(1,200); +COPY copytbl (a, b) from stdin; +ERROR: 23505: duplicate key value violates unique constraint "copytbl_pkey" +DETAIL: Key (a)=(1) already exists. +LOCATION: pgxc_node_report_error, execRemote.c:6284 +drop table copytbl; +\set VERBOSITY default -- #13 -- INSERT query with SELECT part using joins on OID fails to insert all rows correctly create table tmp_films(a int, b text default 'a_tmp_film') with oids; diff --git a/src/test/regress/sql/xl_reported_bugs.sql b/src/test/regress/sql/xl_reported_bugs.sql index ccc751e7d4..a8c84657eb 100644 --- a/src/test/regress/sql/xl_reported_bugs.sql +++ b/src/test/regress/sql/xl_reported_bugs.sql @@ -1,3 +1,17 @@ +-- #74 +-- SQL error codes are not correctly sent back to the client when dealing with error on COPY protocol +\set VERBOSITY verbose +create table copytbl(a integer, b text default 'a_copytbl', primary key (a)); +insert into copytbl select generate_series(1,200); +COPY copytbl (a, b) from stdin; +10000 789 +10001 789 +1 789 +10002 789 +10003 789 +\. +drop table copytbl; +\set VERBOSITY default -- #13 -- INSERT query with SELECT part using joins on OID fails to insert all rows correctly create table tmp_films(a int, b text default 'a_tmp_film') with oids; |