From: teodor Date: Thu, 9 Jul 2009 18:42:21 +0000 (+0000) Subject: Fix test's failure due to fast update of GIN index X-Git-Url: http://www.sigaev.ru/git/gitweb.cgi?p=gevel.git;a=commitdiff_plain;h=1bf3b34c2a2f10e5147c8ba3fd6bf54b5692e35c Fix test's failure due to fast update of GIN index --- diff --git a/expected/gevel.out b/expected/gevel.out index 0faefea..5afe9ed 100644 --- a/expected/gevel.out +++ b/expected/gevel.out @@ -101,6 +101,7 @@ CREATE TABLE test__int( a int[] ); CREATE INDEX gin_idx ON test__int USING gin ( a ); INSERT INTO test__int ( SELECT ARRAY[t] || '{1000}'::_int4 FROM generate_series (1,300) as t ); INSERT INTO test__int ( SELECT ARRAY[t] || '{1001}'::_int4 FROM generate_series (1,300) as t, generate_series(1,12) ); +VACUUM ANALYZE test__int; SELECT * FROM gin_stat('gin_idx') as t(value int, nrow int); value | nrow -------+------ @@ -406,6 +407,6 @@ SELECT * FROM gin_stat('gin_idx') as t(value int, nrow int); 299 | 26 300 | 13 1000 | 300 - 1001 | 3395 + 1001 | 3741 (303 rows) diff --git a/sql/gevel.sql b/sql/gevel.sql index 23aaa8c..50bf184 100644 --- a/sql/gevel.sql +++ b/sql/gevel.sql @@ -22,5 +22,5 @@ CREATE INDEX gin_idx ON test__int USING gin ( a ); INSERT INTO test__int ( SELECT ARRAY[t] || '{1000}'::_int4 FROM generate_series (1,300) as t ); INSERT INTO test__int ( SELECT ARRAY[t] || '{1001}'::_int4 FROM generate_series (1,300) as t, generate_series(1,12) ); - +VACUUM ANALYZE test__int; SELECT * FROM gin_stat('gin_idx') as t(value int, nrow int);