]> granicus.if.org Git - postgresql/commit
Teach genbki.pl to auto-generate pg_type entries for array types.
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 20 Sep 2018 19:14:46 +0000 (15:14 -0400)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 20 Sep 2018 19:14:46 +0000 (15:14 -0400)
commit3dc820c43e427371b66d217f2bd5481fc9ef2e2d
treec8369f7fdadf24358e81851a037abbe1f6d90c5d
parent09e99ce86e3dfb4716618b1dda4074b45ba56a09
Teach genbki.pl to auto-generate pg_type entries for array types.

This eliminates some more tedium in adding new catalog entries,
specifically the need to set up an array type when adding a new
built-in data type.  Now it's sufficient to assign an OID for the
array type and write it in an "array_type_oid" metadata field.
You don't have to fill the base type's typarray link explicitly, either.

No catversion bump since the contents of pg_type aren't changed.
(Well, their order might be different, but that doesn't matter.)

John Naylor, reviewed and whacked around a bit by
Dagfinn Ilmari MannsÃ¥ker, and some more by me.

Discussion: https://postgr.es/m/CAJVSVGVTb6m9pJF49b3SuA8J+T-THO9c0hxOmoyv-yGKh-FbNg@mail.gmail.com
doc/src/sgml/bki.sgml
src/backend/catalog/Catalog.pm
src/backend/catalog/genbki.pl
src/include/catalog/genbki.h
src/include/catalog/pg_type.dat
src/include/catalog/pg_type.h
src/include/catalog/reformat_dat_file.pl