workaround with 8.2.

This commit is contained in:
Takahiro Itagaki
2009-01-27 01:35:53 +00:00
parent aab19c7db0
commit 942180c2d8
5 changed files with 17 additions and 11 deletions

View File

@ -90,7 +90,6 @@ Indexes:
Indexes:
"tbl_only_pkey_pkey" PRIMARY KEY, btree (col1)
SET synchronize_seqscans = off;
SELECT col1, to_char(col2, 'YYYY-MM-DD HH24:MI:SS'), ":-)" FROM tbl_cluster;
col1 | to_char | :-)
------+---------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
@ -122,7 +121,6 @@ SELECT * FROM tbl_gistkey ORDER BY 1;
2 | <(4,5),6>
(2 rows)
RESET synchronize_seqscans;
--
-- clean up
--

View File

@ -581,7 +581,7 @@ reorg_one_table(const reorg_table *table, const char *orderby)
command("BEGIN ISOLATION LEVEL SERIALIZABLE", 0, NULL);
/* SET work_mem = maintenance_work_mem */
command("SELECT set_config('work_mem', current_setting('maintenance_work_mem'), true)", 0, NULL);
if (orderby && !orderby[0])
if (PQserverVersion(current_conn) >= 80300 && orderby && !orderby[0])
command("SET LOCAL synchronize_seqscans = off", 0, NULL);
res = execute(SQL_XID_SNAPSHOT, 0, NULL);
vxid = strdup(PQgetvalue(res, 0, 0));

View File

@ -70,12 +70,10 @@ INSERT INTO tbl_gistkey VALUES(2, '<(4,5),6>');
\d tbl_only_ckey
\d tbl_only_pkey
SET synchronize_seqscans = off;
SELECT col1, to_char(col2, 'YYYY-MM-DD HH24:MI:SS'), ":-)" FROM tbl_cluster;
SELECT * FROM tbl_only_ckey ORDER BY 1;
SELECT * FROM tbl_only_pkey ORDER BY 1;
SELECT * FROM tbl_gistkey ORDER BY 1;
RESET synchronize_seqscans;
--
-- clean up