Re: [GENERAL] "Recheck conditions" on indexes

2013-10-25 Thread Tom Lane
Ivan Voras writes: > I'm just wondering: in the execution plan such as this one, is the > "Recheck Cond" phase what it apparently looks like: an additional check > on the data returned by indexes, and why is it necessary? Bitmap indexscans are potentially lossy. If the bitmap recording all the t

Re: [GENERAL] "Recheck conditions" on indexes

2013-10-25 Thread Ivan Voras
On 25/10/2013 11:06, Albe Laurenz wrote: > Just because there is an entry in the index does not imply that the > corresponding table entry is visible for this transaction. > To ascertain that, the table row itself has to be checked. Understood. > PostgreSQL 9.2 introduced "index only scan" which

Re: [GENERAL] "Recheck conditions" on indexes

2013-10-25 Thread Albe Laurenz
Ivan Voras wrote: > I'm just wondering: in the execution plan such as this one, is the > "Recheck Cond" phase what it apparently looks like: an additional check > on the data returned by indexes, and why is it necessary? I would have > though that indexes are accurate enough? > > cms=> explain ana

[GENERAL] "Recheck conditions" on indexes

2013-10-25 Thread Ivan Voras
Hi, I'm just wondering: in the execution plan such as this one, is the "Recheck Cond" phase what it apparently looks like: an additional check on the data returned by indexes, and why is it necessary? I would have though that indexes are accurate enough? cms=> explain analyze select * from users