Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WSmgi-0003xl-1O for pgsql-bugs@arkaria.postgresql.org; Wed, 26 Mar 2014 12:12:08 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1WSmgh-0003QB-I1 for pgsql-bugs@arkaria.postgresql.org; Wed, 26 Mar 2014 12:12:07 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WSmgg-0003Q5-PC for pgsql-bugs@postgresql.org; Wed, 26 Mar 2014 12:12:06 +0000 Received: from wrigleys.postgresql.org ([204.145.124.246]) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WSmge-0004Yx-8g for pgsql-bugs@postgresql.org; Wed, 26 Mar 2014 12:12:06 +0000 MIME-Version: 1.0 Subject: BUG #9735: Error: "ERROR: tuple offset out of range: 0" during bitmap scan To: pgsql-bugs@postgresql.org From: maxim.boguk@gmail.com Date: Wed, 26 Mar 2014 12:11:11 +0000 Message-ID: <20140326121111.1150.64470@wrigleys.postgresql.org> X-Pg-Spam-Score: -0.3 (/) Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org The following bug has been logged on the website: Bug reference: 9735 Logged by: Maxim Boguk Email address: maxim.boguk@gmail.com PostgreSQL version: 9.3.3 Operating system: Linux Description: Hi, An application start getting curious error during simple query: select * from transactions where (date(provider_tx_datetime) = '2014-03-13'::date); ERROR: tuple offset out of range: 0 Plan: Bitmap Heap Scan on transactions (cost=614.04..32037.39 rows=167485 width=608) Recheck Cond: (date(provider_tx_datetime) = '2014-03-13'::date) -> Bitmap Index Scan on transactions_tx_prv_tx_dt_date_idx21 (cost=0.00..572.17 rows=167485 width=0) Index Cond: (date(provider_tx_datetime) = '2014-03-13'::date) What doesn't helped: set vacuum_freeze_table_age to 0; vacuum freeze verbose transactions; and rebuilding the transactions_tx_prv_tx_dt_date_idx21 index. What helped: set enable_bitmapscan to 0; and executing the same query again with plan: Index Scan using transactions_tx_prv_tx_dt_date_idx21 on transactions (cost=0.56..33915.12 rows=167485 width=608) (actual time=0.047..1233.998 rows=195824 loops=1) Index Cond: (date(provider_tx_datetime) = '2014-03-13'::date) Total runtime: 1247.688 ms afterward. This situation repeated more few times over the last days (with diferen dateranges). Any suggestions where and what for I should look next? It seems somehow related with visibility map and bitmap scan interaction (only my theory though). Kind Regards, Maksym -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs