postgresql/src/include/access
Peter Eisentraut 20e58105ba Separate equalRowTypes() from equalTupleDescs()
This introduces a new function equalRowTypes() that is effectively a
subset of equalTupleDescs() but only compares the number of attributes
and attribute name, type, typmod, and collation.  This is enough for
most existing uses of equalTupleDescs(), which are changed to use the
new function.  The only remaining callers of equalTupleDescs() are
those that really want to check the full tuple descriptor as such,
without concern about record or row or record type semantics.

The existing function hashTupleDesc() is renamed to hashRowType(),
because it now corresponds more to equalRowTypes().

The purpose of this change is to be clearer about the semantics of the
equality asked for by each caller.  (At least one caller had a comment
that questioned whether equalTupleDescs() was too restrictive.)  For
example, 4f622503d6 removed attstattarget from the tuple descriptor
structure.  It was not fully clear at the time how this should affect
equalTupleDescs().  Now the answer is clear: By their own definitions,
equalRowTypes() does not care, and equalTupleDescs() just compares
whatever is in the tuple descriptor but does not care why it is in
there.

Reviewed-by: Tomas Vondra <tomas.vondra@enterprisedb.com>
Discussion: https://www.postgresql.org/message-id/flat/f656d6d9-6660-4518-a006-2f65cafbebd1%40eisentraut.org
2024-03-17 05:58:04 +01:00
..
amapi.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
amvalidate.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
attmap.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
attnum.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
brin.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
brin_internal.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
brin_page.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
brin_pageops.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
brin_revmap.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
brin_tuple.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
brin_xlog.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
bufmask.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
clog.h Improve performance of subsystems on top of SLRU 2024-02-28 17:05:31 +01:00
commit_ts.h Improve performance of subsystems on top of SLRU 2024-02-28 17:05:31 +01:00
detoast.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
genam.h Add try_index_open(), conditional variant of index_open() 2024-01-18 15:04:24 +09:00
generic_xlog.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
gin.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
gin_private.h Use new overflow-safe integer comparison functions. 2024-02-16 14:05:36 -06:00
ginblock.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
ginxlog.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
gist.h Add temporal PRIMARY KEY and UNIQUE constraints 2024-01-24 16:34:37 +01:00
gist_private.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
gistscan.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
gistxlog.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
hash.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
hash_xlog.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
heapam.h Optimize vacuuming of relations with no indexes. 2024-01-18 10:03:42 -05:00
heapam_xlog.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
heaptoast.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
hio.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
htup.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
htup_details.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
itup.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
multixact.h Improve performance of subsystems on top of SLRU 2024-02-28 17:05:31 +01:00
nbtree.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
nbtxlog.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
parallel.h Remove unused ParallelWorkerInfo.pid field 2024-03-04 12:56:02 +02:00
printsimple.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
printtup.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
relation.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
reloptions.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
relscan.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
rewriteheap.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
rmgr.h Pre-beta mechanical code beautification. 2022-05-12 15:17:30 -04:00
rmgrdesc_utils.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
rmgrlist.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
sdir.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
sequence.h Introduce sequence_*() access functions 2024-02-26 16:04:59 +09:00
session.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
skey.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
slru.h Improve performance of subsystems on top of SLRU 2024-02-28 17:05:31 +01:00
spgist.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
spgist_private.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
spgxlog.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
stratnum.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
subtrans.h Improve performance of subsystems on top of SLRU 2024-02-28 17:05:31 +01:00
syncscan.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
sysattr.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
table.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
tableam.h Remove redundant snapshot copying from parallel leader to workers 2024-03-14 15:18:10 +02:00
timeline.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
toast_compression.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
toast_helper.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
toast_internals.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
transam.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
tsmapi.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
tupconvert.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
tupdesc.h Separate equalRowTypes() from equalTupleDescs() 2024-03-17 05:58:04 +01:00
tupdesc_details.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
tupmacs.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
twophase.h Replace BackendIds with 0-based ProcNumbers 2024-03-03 19:38:22 +02:00
twophase_rmgr.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
valid.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
visibilitymap.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
visibilitymapdefs.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xact.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xlog.h Read WAL directly from WAL buffers. 2024-02-12 11:11:22 -08:00
xlog_internal.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xlogarchive.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xlogbackup.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xlogdefs.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xloginsert.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xlogprefetcher.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xlogreader.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xlogrecord.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xlogrecovery.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xlogstats.h Update copyright for 2024 2024-01-03 20:49:05 -05:00
xlogutils.h Update copyright for 2024 2024-01-03 20:49:05 -05:00