You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In this case, the Bitmap Scan cannot use enough memory. So it switches to a lossy algorithm
to store the heap blocks found by the Bitmap Index Scans.
So the Bitmap Heap Scan has to recheck every line in these blocks, which is costly.
These lines are buried in the Misc tab:
Recheck Cond: (((demo.a >= 3) AND (demo.a <= 4)) OR ((demo.a >= 12) AND (demo.a <= 13)))
Rows Removed by Index Recheck: 64896740
Heap Blocks: exact=785621 lossy=743043
pev2 does not show anything else about this 😢
If there is enough memory, you get:
Recheck Cond: (demo.a = ANY ('{3,4}'::bigint[]))
Heap Blocks: exact=90599
and no Rows Removed by Index Recheck (in text mode; it does appear in JSON format with the value 0)
Is your feature request related to a problem? Please describe.
Example: https://explain.dalibo.com/plan/16362e9d7563ff89#plan/node/1
In this case, the
Bitmap Scan
cannot use enough memory. So it switches to a lossy algorithmto store the heap blocks found by the
Bitmap Index Scans
.So the
Bitmap Heap Scan
has to recheck every line in these blocks, which is costly.These lines are buried in the Misc tab:
pev2 does not show anything else about this 😢
If there is enough memory, you get:
and no
Rows Removed by Index Recheck
(in text mode; it does appear in JSON format with the value 0)Another example : https://explain.dalibo.com/plan/7463a5chd8430493
Lossy & Recheck may appear in other cases,
for example with pg_trgm (from https://dali.bo/x2_solutions) : https://explain.dalibo.com/plan/g2d8b1eg1fa6g868
Describe the solution you'd like
This is similar to "Rows removed by Filter" on a Seq Scan, with a different solution.
Rows removed by recheck should appear on the main tab of node if its value > 0 or if « lossy » appears.
The icon, and the algorithm for the colours could be the same than for "Rows removed by Filter" .
The hint in the tooltip could be "Not enough memory, try increasing work_mem".
Describe alternatives you've considered
None
Additional context
None
The text was updated successfully, but these errors were encountered: