File tree 2 files changed +9
-6
lines changed 2 files changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -208,6 +208,11 @@ BitmapHeapNext(BitmapHeapScanState *node)
208
208
209
209
BitmapAdjustPrefetchIterator (node , tbmres );
210
210
211
+ if (tbmres -> ntuples >= 0 )
212
+ node -> exact_pages ++ ;
213
+ else
214
+ node -> lossy_pages ++ ;
215
+
211
216
/*
212
217
* We can skip fetching the heap page if we don't need any fields
213
218
* from the heap, and the bitmap entries don't need rechecking,
@@ -239,11 +244,6 @@ BitmapHeapNext(BitmapHeapScanState *node)
239
244
continue ;
240
245
}
241
246
242
- if (tbmres -> ntuples >= 0 )
243
- node -> exact_pages ++ ;
244
- else
245
- node -> lossy_pages ++ ;
246
-
247
247
/* Adjust the prefetch target */
248
248
BitmapAdjustPrefetchTarget (node );
249
249
}
Original file line number Diff line number Diff line change @@ -2964,6 +2964,7 @@ update ab_a1 set b = 3 from ab where ab.a = 1 and ab.a = ab_a1.a;
2964
2964
Index Cond: (a = 1)
2965
2965
-> Bitmap Heap Scan on ab_a1_b3 ab_a1_b3_1 (actual rows=0 loops=1)
2966
2966
Recheck Cond: (a = 1)
2967
+ Heap Blocks: exact=1
2967
2968
-> Bitmap Index Scan on ab_a1_b3_a_idx (actual rows=1 loops=1)
2968
2969
Index Cond: (a = 1)
2969
2970
-> Materialize (actual rows=1 loops=1)
@@ -2985,14 +2986,16 @@ update ab_a1 set b = 3 from ab where ab.a = 1 and ab.a = ab_a1.a;
2985
2986
Index Cond: (a = 1)
2986
2987
-> Bitmap Heap Scan on ab_a1_b3 ab_a1_b3_1 (actual rows=0 loops=1)
2987
2988
Recheck Cond: (a = 1)
2989
+ Heap Blocks: exact=1
2988
2990
-> Bitmap Index Scan on ab_a1_b3_a_idx (actual rows=1 loops=1)
2989
2991
Index Cond: (a = 1)
2990
2992
-> Materialize (actual rows=0 loops=1)
2991
2993
-> Bitmap Heap Scan on ab_a1_b3 (actual rows=0 loops=1)
2992
2994
Recheck Cond: (a = 1)
2995
+ Heap Blocks: exact=1
2993
2996
-> Bitmap Index Scan on ab_a1_b3_a_idx (actual rows=1 loops=1)
2994
2997
Index Cond: (a = 1)
2995
- (65 rows)
2998
+ (68 rows)
2996
2999
2997
3000
table ab;
2998
3001
a | b
You can’t perform that action at this time.
0 commit comments