[Bizgres-general] Re: Latest bitmap patch results. (tuple offset out of range)

Mark Kirkwood markir at paradise.net.nz
Sat Jan 28 03:40:18 GMT 2006


Ayush Parashar wrote:
> The previous email did not go through, probably because the size of 
> patch + attachment was larger.
> Resending the patch and sending the results with this patch seperately.
> 
> Ayush

I am seeing some offsets being calculated bigger than tidscan.c likes - e.g:


bitmap=# SELECT count(*) FROM bitmaptest WHERE val2 = 70;
ERROR:  tuple offset out of range: 257

If I dump the index (using the fine tutorial example) for value 70:

INFO:  Opened relation with oid 117245
INFO:   max words/page 7140
INFO:   max header words 1020
INFO:  Read meta page (0)
INFO:  LOV heap oid 117246, index oid 117248
INFO:  Read LOV heap relation (bm_internal_t2200bitmaptest_val2_0)
INFO:  LOV value for 70 is located at block, offset (2, 95)
INFO:  Read LOV item at block, offset (2, 95)
INFO:  LOV item has BITMAP head 86 tail 86
INFO:  Processing bitmaps from BITMAP page 86
INFO:  BITMAP 719 words
INFO:  word is 10111111
INFO:  is a compressed word - no. set fill words = 63 at offset 0
INFO:  LOV tid 1 HEAP row at ctid (0, 1)
INFO:  LOV tid 2 HEAP row at ctid (0, 2)
INFO:  LOV tid 3 HEAP row at ctid (0, 3)
...
INFO:  LOV tid 249 HEAP row at ctid (0, 249)
INFO:  LOV tid 250 HEAP row at ctid (0, 250)
INFO:  LOV tid 251 HEAP row at ctid (0, 251)
INFO:  LOV tid 252 HEAP row at ctid (0, 252)
INFO:  LOV tid 253 HEAP row at ctid (0, 253)
INFO:  LOV tid 254 HEAP row at ctid (0, 254)
INFO:  LOV tid 255 HEAP row at ctid (0, 255)
INFO:  LOV tid 256 HEAP row at ctid (0, 256)
INFO:  LOV tid 257 HEAP row at ctid (0, 257)
INFO:  LOV tid 258 HEAP row at ctid (0, 258)
INFO:  LOV tid 259 HEAP row at ctid (0, 259)
...
INFO:  LOV tid 502 HEAP row at ctid (1, 210)
INFO:  LOV tid 503 HEAP row at ctid (1, 211)
INFO:  LOV tid 504 HEAP row at ctid (1, 212)


It looks like there some something not quite right with the set bit run 
encoding for this case, as it has encoded a run for 63 8-bit words...

Cheers

Mark

P.s : I initially thought this was just me doing something silly, , so I 
rebuilt and initdb'ed again. However, I now have a reproducible test 
case (have reproduced on 2 machines).


More information about the Bizgres-general mailing list