Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
8902f792
Commit
8902f792
authored
Feb 20, 2015
by
Alvaro Herrera
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove unnecessary and unreliable test
parent
3b14bb77
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
0 additions
and
130 deletions
+0
-130
src/test/regress/expected/prepared_xacts.out
src/test/regress/expected/prepared_xacts.out
+0
-50
src/test/regress/expected/prepared_xacts_1.out
src/test/regress/expected/prepared_xacts_1.out
+0
-53
src/test/regress/sql/prepared_xacts.sql
src/test/regress/sql/prepared_xacts.sql
+0
-27
No files found.
src/test/regress/expected/prepared_xacts.out
View file @
8902f792
...
@@ -247,58 +247,8 @@ SELECT gid FROM pg_prepared_xacts;
...
@@ -247,58 +247,8 @@ SELECT gid FROM pg_prepared_xacts;
-----
-----
(0 rows)
(0 rows)
CREATE TABLE pxtest5 (a SERIAL);
INSERT INTO pxtest5 DEFAULT VALUES;
SELECT * FROM pxtest5;
a
---
1
(1 row)
BEGIN TRANSACTION ISOLATION LEVEL SERIALIZABLE;
INSERT INTO pxtest5 DEFAULT VALUES;
INSERT INTO pxtest5 DEFAULT VALUES;
TRUNCATE pxtest5;
INSERT INTO pxtest5 DEFAULT VALUES;
PREPARE TRANSACTION 'trunc-and-pgstat';
SELECT pg_sleep(0.5);
pg_sleep
----------
(1 row)
SELECT n_tup_ins, n_tup_upd, n_tup_del, n_live_tup, n_dead_tup
FROM pg_stat_user_tables
WHERE relname='pxtest5';
n_tup_ins | n_tup_upd | n_tup_del | n_live_tup | n_dead_tup
-----------+-----------+-----------+------------+------------
1 | 0 | 0 | 1 | 0
(1 row)
COMMIT PREPARED 'trunc-and-pgstat';
SELECT pg_sleep(0.5);
pg_sleep
----------
(1 row)
SELECT n_tup_ins, n_tup_upd, n_tup_del, n_live_tup, n_dead_tup
FROM pg_stat_user_tables
WHERE relname='pxtest5';
n_tup_ins | n_tup_upd | n_tup_del | n_live_tup | n_dead_tup
-----------+-----------+-----------+------------+------------
2 | 0 | 0 | 1 | 0
(1 row)
SELECT * FROM pxtest5;
a
---
4
(1 row)
-- Clean up
-- Clean up
DROP TABLE pxtest2;
DROP TABLE pxtest2;
DROP TABLE pxtest3; -- will still be there if prepared xacts are disabled
DROP TABLE pxtest3; -- will still be there if prepared xacts are disabled
ERROR: table "pxtest3" does not exist
ERROR: table "pxtest3" does not exist
DROP TABLE pxtest4;
DROP TABLE pxtest4;
DROP TABLE pxtest5;
src/test/regress/expected/prepared_xacts_1.out
View file @
8902f792
...
@@ -249,62 +249,9 @@ SELECT gid FROM pg_prepared_xacts;
...
@@ -249,62 +249,9 @@ SELECT gid FROM pg_prepared_xacts;
-----
-----
(0 rows)
(0 rows)
CREATE TABLE pxtest5 (a SERIAL);
INSERT INTO pxtest5 DEFAULT VALUES;
SELECT * FROM pxtest5;
a
---
1
(1 row)
BEGIN TRANSACTION ISOLATION LEVEL SERIALIZABLE;
INSERT INTO pxtest5 DEFAULT VALUES;
INSERT INTO pxtest5 DEFAULT VALUES;
TRUNCATE pxtest5;
INSERT INTO pxtest5 DEFAULT VALUES;
PREPARE TRANSACTION 'trunc-and-pgstat';
ERROR: prepared transactions are disabled
HINT: Set max_prepared_transactions to a nonzero value.
SELECT pg_sleep(0.5);
pg_sleep
----------
(1 row)
SELECT n_tup_ins, n_tup_upd, n_tup_del, n_live_tup, n_dead_tup
FROM pg_stat_user_tables
WHERE relname='pxtest5';
n_tup_ins | n_tup_upd | n_tup_del | n_live_tup | n_dead_tup
-----------+-----------+-----------+------------+------------
3 | 0 | 0 | 1 | 2
(1 row)
COMMIT PREPARED 'trunc-and-pgstat';
ERROR: prepared transaction with identifier "trunc-and-pgstat" does not exist
SELECT pg_sleep(0.5);
pg_sleep
----------
(1 row)
SELECT n_tup_ins, n_tup_upd, n_tup_del, n_live_tup, n_dead_tup
FROM pg_stat_user_tables
WHERE relname='pxtest5';
n_tup_ins | n_tup_upd | n_tup_del | n_live_tup | n_dead_tup
-----------+-----------+-----------+------------+------------
3 | 0 | 0 | 1 | 2
(1 row)
SELECT * FROM pxtest5;
a
---
1
(1 row)
-- Clean up
-- Clean up
DROP TABLE pxtest2;
DROP TABLE pxtest2;
ERROR: table "pxtest2" does not exist
ERROR: table "pxtest2" does not exist
DROP TABLE pxtest3; -- will still be there if prepared xacts are disabled
DROP TABLE pxtest3; -- will still be there if prepared xacts are disabled
DROP TABLE pxtest4;
DROP TABLE pxtest4;
ERROR: table "pxtest4" does not exist
ERROR: table "pxtest4" does not exist
DROP TABLE pxtest5;
src/test/regress/sql/prepared_xacts.sql
View file @
8902f792
...
@@ -152,34 +152,7 @@ SELECT * FROM pxtest3;
...
@@ -152,34 +152,7 @@ SELECT * FROM pxtest3;
-- There should be no prepared transactions
-- There should be no prepared transactions
SELECT
gid
FROM
pg_prepared_xacts
;
SELECT
gid
FROM
pg_prepared_xacts
;
CREATE
TABLE
pxtest5
(
a
SERIAL
);
INSERT
INTO
pxtest5
DEFAULT
VALUES
;
SELECT
*
FROM
pxtest5
;
BEGIN
TRANSACTION
ISOLATION
LEVEL
SERIALIZABLE
;
INSERT
INTO
pxtest5
DEFAULT
VALUES
;
INSERT
INTO
pxtest5
DEFAULT
VALUES
;
TRUNCATE
pxtest5
;
INSERT
INTO
pxtest5
DEFAULT
VALUES
;
PREPARE
TRANSACTION
'trunc-and-pgstat'
;
SELECT
pg_sleep
(
0
.
5
);
SELECT
n_tup_ins
,
n_tup_upd
,
n_tup_del
,
n_live_tup
,
n_dead_tup
FROM
pg_stat_user_tables
WHERE
relname
=
'pxtest5'
;
COMMIT
PREPARED
'trunc-and-pgstat'
;
SELECT
pg_sleep
(
0
.
5
);
SELECT
n_tup_ins
,
n_tup_upd
,
n_tup_del
,
n_live_tup
,
n_dead_tup
FROM
pg_stat_user_tables
WHERE
relname
=
'pxtest5'
;
SELECT
*
FROM
pxtest5
;
-- Clean up
-- Clean up
DROP
TABLE
pxtest2
;
DROP
TABLE
pxtest2
;
DROP
TABLE
pxtest3
;
-- will still be there if prepared xacts are disabled
DROP
TABLE
pxtest3
;
-- will still be there if prepared xacts are disabled
DROP
TABLE
pxtest4
;
DROP
TABLE
pxtest4
;
DROP
TABLE
pxtest5
;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment