Re: [HACKERS] [PATCH] Generic type subscripting - Mailing list pgsql-hackers

From Pavel Stehule
Subject Re: [HACKERS] [PATCH] Generic type subscripting
Date
Msg-id CAFj8pRC-bW95n5pfbc8vN2Qk3oOjoCLHtrzg89hztE0JUiq6Gw@mail.gmail.com
Whole thread Raw
In response to Re: [HACKERS] [PATCH] Generic type subscripting  (Dmitry Dolgov <9erthalion6@gmail.com>)
Responses Re: [HACKERS] [PATCH] Generic type subscripting
List pgsql-hackers
Hi

probably some is wrong still

create table foo(a jsonb);
update foo set a['a'] = '10';
update foo set a['b']['c'][1] = '10';
update foo set a['b']['c'][10] = '10'

WARNING:  problem in alloc set ExprContext: req size > alloc size for chunk 0x256dd88 in block 0x256d160
WARNING:  problem in alloc set ExprContext: bogus aset link in block 0x256d160, chunk 0x256dd88
WARNING:  problem in alloc set ExprContext: req size > alloc size for chunk 0x256dfa0 in block 0x256d160
WARNING:  problem in alloc set ExprContext: bogus aset link in block 0x256d160, chunk 0x256dfa0
WARNING:  problem in alloc set ExprContext: req size > alloc size for chunk 0x256dfc4 in block 0x256d160
WARNING:  problem in alloc set ExprContext: bad single-chunk 0x256dfc4 in block 0x256d160
WARNING:  problem in alloc set ExprContext: bogus aset link in block 0x256d160, chunk 0x256dfc4
WARNING:  problem in alloc set ExprContext: found inconsistent memory block 0x256d160
UPDATE 1

and result is wrong, the value of a['b']['c'][1] was overwritten by NULL

Regards

Pavel

pgsql-hackers by date:

Previous
From: David Fetter
Date:
Subject: Re: Implement for window functions
Next
From: Justin Pryzby
Date:
Subject: Re: zstd compression for pg_dump