Opened 17 months ago
Closed 17 months ago
#5427 closed defect (fixed)
PG17 change broke our code
Reported by: | robe | Owned by: | pramsey |
---|---|---|---|
Priority: | blocker | Milestone: | PostGIS 3.5.0 |
Component: | postgis | Version: | master |
Keywords: | PostgreSQL 17 pg17 | Cc: |
Description
/pg/rel/pg16w64/include/postgresql/internal -D_GNU_SOURCE -c -o gserialized_estimate.o gserialized_estimate.c gserialized_estimate.c: In function ‘compute_gserialized_stats_mode’: gserialized_estimate.c:1521:46: error: ‘VacAttrStats’ has no member named ‘attr’ 1521 | histo_cells_target = (int)pow((double)(stats->attr->attstattarget), (double)ndims); | ^~ make[1]: *** [<builtin>: gserialized_estimate.o] Error 1 make[1]: Leaving directory '/var/lib/jenkins/workspace/postgis/regress_pgdev/branches/3.4/postgis' make: *** [GNUmakefile:25: all] Error 1 Build step 'Execute shell' marked build as failure Finished: FAILURE
guessing the cause was this commit: https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=c69bdf837f161ae3e699496be10215dbb2315917
Take pg_attribute out of VacAttrStats The VacAttrStats structure contained the whole Form_pg_attribute for a column, but it actually only needs attstattarget from there. So remove the Form_pg_attribute field and make a separate field for attstattarget. This simplifies some code for extended statistics that doesn't deal with a column but an expression, which had to fake up pg_attribute rows to satisfy internal APIs. Also, we can remove some comments that essentially said "don't look at pg_attribute directly".
Change History (4)
comment:1 by , 17 months ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:2 by , 17 months ago
The patch is not good enough.
You forgot to fix the references to stats->attr
that are in the code block surrounded by #if POSTGIS_DEBUG_LEVEL > 0
, at line 1535.
comment:3 by , 17 months ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Note:
See TracTickets
for help on using tickets.
In dc1fe8f/git: