From: | Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com> |
---|---|
To: | Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
Cc: | Justin Pryzby <pryzby(at)telsasoft(dot)com>, Matthias van de Meent <boekewurm+postgres(at)gmail(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: Missing update of all_hasnulls in BRIN opclasses |
Date: | 2023-04-23 20:43:44 |
Message-ID: | 24ef13a1-b798-0a5f-33c0-e6cf9e65492a@enterprisedb.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
here's an updated version of the patch, including a backport version. I
ended up making the code yet a bit closer to master by introducing
add_values_to_range(). The current pre-14 code has the loop adding data
to the BRIN tuple in two places, but with the "fixed" logic handling
NULLs and the empty_range flag the amount of duplicated code got too
high, so this seem reasonable.
Both cases have a patch extending pageinspect to show the new flag, but
obviously we should commit that only in master. In backbranches it's
meant only to make testing easier.
I plan to do a bit more testing, I'd welcome some feedback - it's a
long-standing bug, and it'd be good to finally get this fixed. I don't
think the patch can be made any simpler.
regards
--
Tomas Vondra
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
Attachment | Content-Type | Size |
---|---|---|
0001-Fix-handling-of-NULLs-in-BRIN-indexes-20230423-11-13.patch | text/x-patch | 18.3 KB |
0002-pageinspect-tweak-20230423-11-13.patch | text/x-patch | 2.5 KB |
0001-Fix-handling-of-NULLs-in-BRIN-indexe-20230423-master.patch | text/x-patch | 13.8 KB |
0002-Show-empty-ranges-in-brin_page_items-20230423-master.patch | text/x-patch | 6.9 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Magnus Hagander | 2023-04-23 21:52:24 | Re: run pgindent on a regular basis / scripted manner |
Previous Message | Isaac Morland | 2023-04-23 17:46:45 | Re: xmlserialize bug - extra empty row at the end |