pg_query 5.1.0 → 6.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +30 -0
- data/README.md +1 -1
- data/Rakefile +4 -4
- data/ext/pg_query/ext_symbols_freebsd.sym +1 -0
- data/ext/pg_query/ext_symbols_freebsd_with_ruby_abi_version.sym +2 -0
- data/ext/pg_query/ext_symbols_openbsd.sym +1 -0
- data/ext/pg_query/ext_symbols_openbsd_with_ruby_abi_version.sym +2 -0
- data/ext/pg_query/ext_symbols_with_ruby_abi_version.sym +2 -0
- data/ext/pg_query/extconf.rb +20 -6
- data/ext/pg_query/include/pg_query.h +4 -3
- data/ext/pg_query/include/pg_query_enum_defs.c +424 -154
- data/ext/pg_query/include/pg_query_fingerprint_conds.c +68 -4
- data/ext/pg_query/include/pg_query_fingerprint_defs.c +2952 -1845
- data/ext/pg_query/include/pg_query_outfuncs_conds.c +51 -3
- data/ext/pg_query/include/pg_query_outfuncs_defs.c +210 -23
- data/ext/pg_query/include/pg_query_readfuncs_conds.c +17 -1
- data/ext/pg_query/include/pg_query_readfuncs_defs.c +271 -52
- data/ext/pg_query/include/postgres/access/amapi.h +14 -3
- data/ext/pg_query/include/postgres/access/attmap.h +1 -1
- data/ext/pg_query/include/postgres/access/attnum.h +1 -1
- data/ext/pg_query/include/postgres/access/brin_internal.h +116 -0
- data/ext/pg_query/include/postgres/access/brin_tuple.h +112 -0
- data/ext/pg_query/include/postgres/access/clog.h +2 -3
- data/ext/pg_query/include/postgres/access/commit_ts.h +2 -3
- data/ext/pg_query/include/postgres/access/detoast.h +1 -1
- data/ext/pg_query/include/postgres/access/genam.h +17 -4
- data/ext/pg_query/include/postgres/access/gin.h +1 -1
- data/ext/pg_query/include/postgres/access/htup.h +1 -1
- data/ext/pg_query/include/postgres/access/htup_details.h +11 -11
- data/ext/pg_query/include/postgres/access/itup.h +3 -3
- data/ext/pg_query/include/postgres/access/parallel.h +1 -2
- data/ext/pg_query/include/postgres/access/printtup.h +1 -1
- data/ext/pg_query/include/postgres/access/relation.h +1 -1
- data/ext/pg_query/include/postgres/access/relscan.h +1 -1
- data/ext/pg_query/include/postgres/access/rmgrlist.h +1 -1
- data/ext/pg_query/include/postgres/access/sdir.h +1 -1
- data/ext/pg_query/include/postgres/access/skey.h +1 -1
- data/ext/pg_query/include/postgres/access/slru.h +218 -0
- data/ext/pg_query/include/postgres/access/stratnum.h +1 -1
- data/ext/pg_query/include/postgres/access/sysattr.h +1 -1
- data/ext/pg_query/include/postgres/access/table.h +1 -1
- data/ext/pg_query/include/postgres/access/tableam.h +35 -25
- data/ext/pg_query/include/postgres/access/tidstore.h +50 -0
- data/ext/pg_query/include/postgres/access/toast_compression.h +2 -2
- data/ext/pg_query/include/postgres/access/transam.h +50 -7
- data/ext/pg_query/include/postgres/access/tsmapi.h +1 -1
- data/ext/pg_query/include/postgres/access/tupconvert.h +1 -1
- data/ext/pg_query/include/postgres/access/tupdesc.h +5 -5
- data/ext/pg_query/include/postgres/access/tupmacs.h +1 -1
- data/ext/pg_query/include/postgres/access/twophase.h +2 -2
- data/ext/pg_query/include/postgres/access/xact.h +5 -5
- data/ext/pg_query/include/postgres/access/xlog.h +20 -12
- data/ext/pg_query/include/postgres/access/xlog_internal.h +4 -3
- data/ext/pg_query/include/postgres/access/xlogbackup.h +3 -1
- data/ext/pg_query/include/postgres/access/xlogdefs.h +5 -5
- data/ext/pg_query/include/postgres/access/xlogprefetcher.h +2 -2
- data/ext/pg_query/include/postgres/access/xlogreader.h +2 -2
- data/ext/pg_query/include/postgres/access/xlogrecord.h +3 -3
- data/ext/pg_query/include/postgres/access/xlogrecovery.h +4 -4
- data/ext/pg_query/include/postgres/archive/archive_module.h +9 -1
- data/ext/pg_query/include/postgres/c.h +32 -37
- data/ext/pg_query/include/postgres/catalog/catalog.h +3 -1
- data/ext/pg_query/include/postgres/catalog/catversion.h +2 -2
- data/ext/pg_query/include/postgres/catalog/dependency.h +17 -59
- data/ext/pg_query/include/postgres/catalog/genbki.h +12 -6
- data/ext/pg_query/include/postgres/catalog/index.h +22 -18
- data/ext/pg_query/include/postgres/catalog/indexing.h +1 -1
- data/ext/pg_query/include/postgres/catalog/namespace.h +18 -19
- data/ext/pg_query/include/postgres/catalog/objectaccess.h +2 -2
- data/ext/pg_query/include/postgres/catalog/objectaddress.h +5 -1
- data/ext/pg_query/include/postgres/catalog/pg_aggregate.h +4 -2
- data/ext/pg_query/include/postgres/catalog/pg_aggregate_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_am.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_am_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_attribute.h +31 -14
- data/ext/pg_query/include/postgres/catalog/pg_attribute_d.h +3 -3
- data/ext/pg_query/include/postgres/catalog/pg_authid.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_authid_d.h +2 -1
- data/ext/pg_query/include/postgres/catalog/pg_class.h +10 -5
- data/ext/pg_query/include/postgres/catalog/pg_class_d.h +4 -2
- data/ext/pg_query/include/postgres/catalog/pg_collation.h +11 -5
- data/ext/pg_query/include/postgres/catalog/pg_collation_d.h +5 -2
- data/ext/pg_query/include/postgres/catalog/pg_constraint.h +15 -10
- data/ext/pg_query/include/postgres/catalog/pg_constraint_d.h +2 -1
- data/ext/pg_query/include/postgres/catalog/pg_control.h +5 -3
- data/ext/pg_query/include/postgres/catalog/pg_conversion.h +8 -4
- data/ext/pg_query/include/postgres/catalog/pg_conversion_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_database.h +9 -4
- data/ext/pg_query/include/postgres/catalog/pg_database_d.h +13 -12
- data/ext/pg_query/include/postgres/catalog/pg_depend.h +3 -3
- data/ext/pg_query/include/postgres/catalog/pg_depend_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_event_trigger.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_event_trigger_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_index.h +5 -3
- data/ext/pg_query/include/postgres/catalog/pg_index_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_language.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_language_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_namespace.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_namespace_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_opclass.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_opclass_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_operator.h +20 -3
- data/ext/pg_query/include/postgres/catalog/pg_operator_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_opfamily.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_opfamily_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_partitioned_table.h +4 -2
- data/ext/pg_query/include/postgres/catalog/pg_partitioned_table_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_proc.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_proc_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_publication.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_publication_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_replication_origin.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_replication_origin_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_statistic.h +10 -4
- data/ext/pg_query/include/postgres/catalog/pg_statistic_d.h +7 -3
- data/ext/pg_query/include/postgres/catalog/pg_statistic_ext.h +10 -7
- data/ext/pg_query/include/postgres/catalog/pg_statistic_ext_d.h +3 -3
- data/ext/pg_query/include/postgres/catalog/pg_transform.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_transform_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_trigger.h +4 -4
- data/ext/pg_query/include/postgres/catalog/pg_trigger_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_ts_config.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_ts_config_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_ts_dict.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_ts_dict_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_ts_parser.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_ts_parser_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_ts_template.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_ts_template_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/pg_type.h +6 -3
- data/ext/pg_query/include/postgres/catalog/pg_type_d.h +1 -1
- data/ext/pg_query/include/postgres/catalog/storage.h +1 -1
- data/ext/pg_query/include/postgres/catalog/syscache_ids.h +104 -0
- data/ext/pg_query/include/postgres/commands/async.h +2 -6
- data/ext/pg_query/include/postgres/commands/dbcommands.h +1 -1
- data/ext/pg_query/include/postgres/commands/defrem.h +6 -6
- data/ext/pg_query/include/postgres/commands/event_trigger.h +11 -2
- data/ext/pg_query/include/postgres/commands/explain.h +19 -3
- data/ext/pg_query/include/postgres/commands/prepare.h +1 -1
- data/ext/pg_query/include/postgres/commands/tablespace.h +1 -1
- data/ext/pg_query/include/postgres/commands/trigger.h +1 -1
- data/ext/pg_query/include/postgres/commands/vacuum.h +28 -26
- data/ext/pg_query/include/postgres/common/cryptohash.h +2 -2
- data/ext/pg_query/include/postgres/common/file_perm.h +1 -1
- data/ext/pg_query/include/postgres/common/file_utils.h +65 -0
- data/ext/pg_query/include/postgres/common/hashfn.h +16 -1
- data/ext/pg_query/include/postgres/common/hashfn_unstable.h +407 -0
- data/ext/pg_query/include/postgres/common/int.h +79 -4
- data/ext/pg_query/include/postgres/common/keywords.h +1 -1
- data/ext/pg_query/include/postgres/common/kwlookup.h +1 -1
- data/ext/pg_query/include/postgres/common/pg_prng.h +2 -1
- data/ext/pg_query/include/postgres/common/relpath.h +4 -4
- data/ext/pg_query/include/postgres/common/scram-common.h +1 -1
- data/ext/pg_query/include/postgres/common/sha2.h +1 -1
- data/ext/pg_query/include/postgres/common/string.h +1 -1
- data/ext/pg_query/include/postgres/common/unicode_east_asian_fw_table.h +2 -3
- data/ext/pg_query/include/postgres/copyfuncs.funcs.c +278 -30
- data/ext/pg_query/include/postgres/copyfuncs.switch.c +55 -4
- data/ext/pg_query/include/postgres/datatype/timestamp.h +29 -3
- data/ext/pg_query/include/postgres/equalfuncs.funcs.c +239 -26
- data/ext/pg_query/include/postgres/equalfuncs.switch.c +55 -4
- data/ext/pg_query/include/postgres/executor/execdesc.h +2 -2
- data/ext/pg_query/include/postgres/executor/executor.h +6 -5
- data/ext/pg_query/include/postgres/executor/functions.h +2 -1
- data/ext/pg_query/include/postgres/executor/instrument.h +5 -3
- data/ext/pg_query/include/postgres/executor/spi.h +2 -8
- data/ext/pg_query/include/postgres/executor/tablefunc.h +1 -1
- data/ext/pg_query/include/postgres/executor/tuptable.h +31 -2
- data/ext/pg_query/include/postgres/fmgr.h +2 -2
- data/ext/pg_query/include/postgres/foreign/fdwapi.h +1 -1
- data/ext/pg_query/include/postgres/funcapi.h +2 -2
- data/ext/pg_query/include/postgres/gram.h +871 -830
- data/ext/pg_query/include/postgres/gramparse.h +1 -1
- data/ext/pg_query/include/postgres/jit/jit.h +4 -3
- data/ext/pg_query/include/postgres/kwlist_d.h +511 -466
- data/ext/pg_query/include/postgres/lib/dshash.h +25 -10
- data/ext/pg_query/include/postgres/lib/ilist.h +1 -1
- data/ext/pg_query/include/postgres/lib/pairingheap.h +1 -1
- data/ext/pg_query/include/postgres/lib/simplehash.h +40 -18
- data/ext/pg_query/include/postgres/lib/sort_template.h +14 -1
- data/ext/pg_query/include/postgres/lib/stringinfo.h +93 -11
- data/ext/pg_query/include/postgres/libpq/auth.h +1 -1
- data/ext/pg_query/include/postgres/libpq/crypt.h +2 -2
- data/ext/pg_query/include/postgres/libpq/hba.h +4 -4
- data/ext/pg_query/include/postgres/libpq/libpq-be.h +35 -28
- data/ext/pg_query/include/postgres/libpq/libpq.h +6 -7
- data/ext/pg_query/include/postgres/libpq/pqcomm.h +26 -20
- data/ext/pg_query/include/postgres/libpq/pqformat.h +2 -3
- data/ext/pg_query/include/postgres/libpq/pqsignal.h +1 -1
- data/ext/pg_query/include/postgres/libpq/protocol.h +89 -0
- data/ext/pg_query/include/postgres/libpq/sasl.h +1 -1
- data/ext/pg_query/include/postgres/libpq/scram.h +1 -1
- data/ext/pg_query/include/postgres/mb/pg_wchar.h +103 -82
- data/ext/pg_query/include/postgres/mb/stringinfo_mb.h +1 -1
- data/ext/pg_query/include/postgres/miscadmin.h +72 -52
- data/ext/pg_query/include/postgres/nodes/bitmapset.h +17 -3
- data/ext/pg_query/include/postgres/nodes/execnodes.h +112 -25
- data/ext/pg_query/include/postgres/nodes/extensible.h +1 -1
- data/ext/pg_query/include/postgres/nodes/lockoptions.h +4 -4
- data/ext/pg_query/include/postgres/nodes/makefuncs.h +8 -2
- data/ext/pg_query/include/postgres/nodes/memnodes.h +43 -4
- data/ext/pg_query/include/postgres/nodes/miscnodes.h +1 -1
- data/ext/pg_query/include/postgres/nodes/nodeFuncs.h +1 -1
- data/ext/pg_query/include/postgres/nodes/nodes.h +30 -41
- data/ext/pg_query/include/postgres/nodes/nodetags.h +464 -444
- data/ext/pg_query/include/postgres/nodes/params.h +1 -1
- data/ext/pg_query/include/postgres/nodes/parsenodes.h +358 -175
- data/ext/pg_query/include/postgres/nodes/pathnodes.h +64 -10
- data/ext/pg_query/include/postgres/nodes/pg_list.h +62 -11
- data/ext/pg_query/include/postgres/nodes/plannodes.h +11 -10
- data/ext/pg_query/include/postgres/nodes/primnodes.h +352 -54
- data/ext/pg_query/include/postgres/nodes/print.h +1 -1
- data/ext/pg_query/include/postgres/nodes/queryjumble.h +2 -2
- data/ext/pg_query/include/postgres/nodes/replnodes.h +23 -2
- data/ext/pg_query/include/postgres/nodes/supportnodes.h +1 -1
- data/ext/pg_query/include/postgres/nodes/tidbitmap.h +1 -1
- data/ext/pg_query/include/postgres/nodes/value.h +1 -1
- data/ext/pg_query/include/postgres/optimizer/cost.h +5 -4
- data/ext/pg_query/include/postgres/optimizer/geqo.h +1 -1
- data/ext/pg_query/include/postgres/optimizer/geqo_gene.h +1 -1
- data/ext/pg_query/include/postgres/optimizer/optimizer.h +5 -2
- data/ext/pg_query/include/postgres/optimizer/paths.h +13 -8
- data/ext/pg_query/include/postgres/optimizer/planmain.h +7 -1
- data/ext/pg_query/include/postgres/parser/analyze.h +3 -1
- data/ext/pg_query/include/postgres/parser/kwlist.h +22 -2
- data/ext/pg_query/include/postgres/parser/parse_agg.h +1 -1
- data/ext/pg_query/include/postgres/parser/parse_coerce.h +5 -2
- data/ext/pg_query/include/postgres/parser/parse_expr.h +1 -1
- data/ext/pg_query/include/postgres/parser/parse_func.h +2 -2
- data/ext/pg_query/include/postgres/parser/parse_node.h +3 -2
- data/ext/pg_query/include/postgres/parser/parse_oper.h +4 -1
- data/ext/pg_query/include/postgres/parser/parse_relation.h +1 -1
- data/ext/pg_query/include/postgres/parser/parse_type.h +2 -2
- data/ext/pg_query/include/postgres/parser/parser.h +3 -3
- data/ext/pg_query/include/postgres/parser/parsetree.h +1 -1
- data/ext/pg_query/include/postgres/parser/scanner.h +1 -1
- data/ext/pg_query/include/postgres/parser/scansup.h +1 -1
- data/ext/pg_query/include/postgres/partitioning/partdefs.h +1 -1
- data/ext/pg_query/include/postgres/pg_config.h +53 -45
- data/ext/pg_query/include/postgres/pg_config_manual.h +21 -8
- data/ext/pg_query/include/postgres/pg_getopt.h +1 -1
- data/ext/pg_query/include/postgres/pg_trace.h +1 -1
- data/ext/pg_query/include/postgres/pgstat.h +13 -11
- data/ext/pg_query/include/postgres/pgtime.h +1 -1
- data/ext/pg_query/include/postgres/pl_reserved_kwlist.h +1 -1
- data/ext/pg_query/include/postgres/pl_reserved_kwlist_d.h +1 -1
- data/ext/pg_query/include/postgres/pl_unreserved_kwlist.h +1 -1
- data/ext/pg_query/include/postgres/pl_unreserved_kwlist_d.h +1 -1
- data/ext/pg_query/include/postgres/plerrcodes.h +4 -4
- data/ext/pg_query/include/postgres/plpgsql.h +15 -13
- data/ext/pg_query/include/postgres/port/atomics/arch-arm.h +1 -1
- data/ext/pg_query/include/postgres/port/atomics/arch-hppa.h +1 -1
- data/ext/pg_query/include/postgres/port/atomics/arch-ppc.h +3 -1
- data/ext/pg_query/include/postgres/port/atomics/arch-x86.h +3 -1
- data/ext/pg_query/include/postgres/port/atomics/fallback.h +1 -1
- data/ext/pg_query/include/postgres/port/atomics/generic-gcc.h +38 -1
- data/ext/pg_query/include/postgres/port/atomics/generic-msvc.h +19 -1
- data/ext/pg_query/include/postgres/port/atomics/generic-sunpro.h +16 -1
- data/ext/pg_query/include/postgres/port/atomics/generic.h +38 -2
- data/ext/pg_query/include/postgres/port/atomics.h +93 -6
- data/ext/pg_query/include/postgres/port/pg_bitutils.h +91 -9
- data/ext/pg_query/include/postgres/port/pg_bswap.h +1 -1
- data/ext/pg_query/include/postgres/port/pg_crc32c.h +10 -1
- data/ext/pg_query/include/postgres/port/pg_iovec.h +117 -0
- data/ext/pg_query/include/postgres/port/simd.h +48 -1
- data/ext/pg_query/include/postgres/port/win32/sys/socket.h +8 -0
- data/ext/pg_query/include/postgres/port/win32_port.h +1 -13
- data/ext/pg_query/include/postgres/port.h +39 -4
- data/ext/pg_query/include/postgres/portability/instr_time.h +1 -1
- data/ext/pg_query/include/postgres/postgres.h +1 -1
- data/ext/pg_query/include/postgres/postmaster/autovacuum.h +5 -16
- data/ext/pg_query/include/postgres/postmaster/bgworker.h +8 -6
- data/ext/pg_query/include/postgres/postmaster/bgworker_internals.h +3 -7
- data/ext/pg_query/include/postgres/postmaster/bgwriter.h +3 -3
- data/ext/pg_query/include/postgres/postmaster/interrupt.h +1 -1
- data/ext/pg_query/include/postgres/postmaster/pgarch.h +2 -2
- data/ext/pg_query/include/postgres/postmaster/postmaster.h +25 -5
- data/ext/pg_query/include/postgres/postmaster/startup.h +2 -2
- data/ext/pg_query/include/postgres/postmaster/syslogger.h +2 -4
- data/ext/pg_query/include/postgres/postmaster/walsummarizer.h +35 -0
- data/ext/pg_query/include/postgres/postmaster/walwriter.h +2 -2
- data/ext/pg_query/include/postgres/regex/regex.h +92 -9
- data/ext/pg_query/include/postgres/replication/logicallauncher.h +1 -1
- data/ext/pg_query/include/postgres/replication/logicalproto.h +2 -2
- data/ext/pg_query/include/postgres/replication/logicalworker.h +2 -1
- data/ext/pg_query/include/postgres/replication/origin.h +1 -1
- data/ext/pg_query/include/postgres/replication/reorderbuffer.h +27 -46
- data/ext/pg_query/include/postgres/replication/slot.h +45 -5
- data/ext/pg_query/include/postgres/replication/slotsync.h +38 -0
- data/ext/pg_query/include/postgres/replication/syncrep.h +1 -1
- data/ext/pg_query/include/postgres/replication/walreceiver.h +37 -11
- data/ext/pg_query/include/postgres/replication/walsender.h +5 -3
- data/ext/pg_query/include/postgres/rewrite/prs2lock.h +1 -1
- data/ext/pg_query/include/postgres/rewrite/rewriteHandler.h +7 -1
- data/ext/pg_query/include/postgres/rewrite/rewriteManip.h +2 -2
- data/ext/pg_query/include/postgres/rewrite/rewriteSupport.h +1 -1
- data/ext/pg_query/include/postgres/storage/block.h +1 -1
- data/ext/pg_query/include/postgres/storage/buf.h +1 -1
- data/ext/pg_query/include/postgres/storage/bufmgr.h +59 -41
- data/ext/pg_query/include/postgres/storage/bufpage.h +1 -1
- data/ext/pg_query/include/postgres/storage/condition_variable.h +1 -1
- data/ext/pg_query/include/postgres/storage/dsm.h +1 -1
- data/ext/pg_query/include/postgres/storage/dsm_impl.h +2 -2
- data/ext/pg_query/include/postgres/storage/fd.h +30 -13
- data/ext/pg_query/include/postgres/storage/fileset.h +1 -1
- data/ext/pg_query/include/postgres/storage/ipc.h +4 -1
- data/ext/pg_query/include/postgres/storage/item.h +1 -1
- data/ext/pg_query/include/postgres/storage/itemid.h +1 -1
- data/ext/pg_query/include/postgres/storage/itemptr.h +1 -1
- data/ext/pg_query/include/postgres/storage/large_object.h +1 -1
- data/ext/pg_query/include/postgres/storage/latch.h +4 -2
- data/ext/pg_query/include/postgres/storage/lmgr.h +8 -2
- data/ext/pg_query/include/postgres/storage/lock.h +19 -19
- data/ext/pg_query/include/postgres/storage/lockdefs.h +3 -1
- data/ext/pg_query/include/postgres/storage/lwlock.h +17 -9
- data/ext/pg_query/include/postgres/storage/lwlocknames.h +7 -10
- data/ext/pg_query/include/postgres/storage/off.h +1 -1
- data/ext/pg_query/include/postgres/storage/pg_sema.h +1 -1
- data/ext/pg_query/include/postgres/storage/pg_shmem.h +5 -4
- data/ext/pg_query/include/postgres/storage/pmsignal.h +2 -2
- data/ext/pg_query/include/postgres/storage/predicate.h +1 -5
- data/ext/pg_query/include/postgres/storage/proc.h +48 -26
- data/ext/pg_query/include/postgres/storage/procarray.h +5 -1
- data/ext/pg_query/include/postgres/storage/proclist_types.h +11 -9
- data/ext/pg_query/include/postgres/storage/procnumber.h +43 -0
- data/ext/pg_query/include/postgres/storage/procsignal.h +8 -6
- data/ext/pg_query/include/postgres/storage/read_stream.h +65 -0
- data/ext/pg_query/include/postgres/storage/relfilelocator.h +16 -15
- data/ext/pg_query/include/postgres/storage/s_lock.h +7 -27
- data/ext/pg_query/include/postgres/storage/sharedfileset.h +1 -1
- data/ext/pg_query/include/postgres/storage/shm_mq.h +2 -2
- data/ext/pg_query/include/postgres/storage/shm_toc.h +1 -1
- data/ext/pg_query/include/postgres/storage/shmem.h +1 -1
- data/ext/pg_query/include/postgres/storage/sinval.h +3 -3
- data/ext/pg_query/include/postgres/storage/smgr.h +46 -29
- data/ext/pg_query/include/postgres/storage/spin.h +1 -1
- data/ext/pg_query/include/postgres/storage/standby.h +13 -3
- data/ext/pg_query/include/postgres/storage/standbydefs.h +2 -2
- data/ext/pg_query/include/postgres/storage/sync.h +4 -4
- data/ext/pg_query/include/postgres/tcop/cmdtag.h +1 -2
- data/ext/pg_query/include/postgres/tcop/cmdtaglist.h +3 -2
- data/ext/pg_query/include/postgres/tcop/deparse_utility.h +2 -2
- data/ext/pg_query/include/postgres/tcop/dest.h +3 -2
- data/ext/pg_query/include/postgres/tcop/fastpath.h +1 -1
- data/ext/pg_query/include/postgres/tcop/pquery.h +1 -1
- data/ext/pg_query/include/postgres/tcop/tcopprot.h +9 -5
- data/ext/pg_query/include/postgres/tcop/utility.h +2 -2
- data/ext/pg_query/include/postgres/tsearch/ts_cache.h +1 -1
- data/ext/pg_query/include/postgres/utils/acl.h +19 -7
- data/ext/pg_query/include/postgres/utils/aclchk_internal.h +1 -1
- data/ext/pg_query/include/postgres/utils/array.h +1 -2
- data/ext/pg_query/include/postgres/utils/ascii.h +84 -0
- data/ext/pg_query/include/postgres/utils/backend_progress.h +3 -2
- data/ext/pg_query/include/postgres/utils/backend_status.h +8 -10
- data/ext/pg_query/include/postgres/utils/builtins.h +4 -1
- data/ext/pg_query/include/postgres/utils/bytea.h +2 -2
- data/ext/pg_query/include/postgres/utils/catcache.h +6 -6
- data/ext/pg_query/include/postgres/utils/date.h +1 -1
- data/ext/pg_query/include/postgres/utils/datetime.h +4 -1
- data/ext/pg_query/include/postgres/utils/datum.h +1 -1
- data/ext/pg_query/include/postgres/utils/dsa.h +44 -5
- data/ext/pg_query/include/postgres/utils/elog.h +3 -8
- data/ext/pg_query/include/postgres/utils/errcodes.h +1 -3
- data/ext/pg_query/include/postgres/utils/expandeddatum.h +1 -1
- data/ext/pg_query/include/postgres/utils/expandedrecord.h +1 -1
- data/ext/pg_query/include/postgres/utils/float.h +1 -1
- data/ext/pg_query/include/postgres/utils/fmgroids.h +49 -16
- data/ext/pg_query/include/postgres/utils/fmgrprotos.h +47 -14
- data/ext/pg_query/include/postgres/utils/fmgrtab.h +1 -1
- data/ext/pg_query/include/postgres/utils/guc.h +20 -6
- data/ext/pg_query/include/postgres/utils/guc_hooks.h +23 -2
- data/ext/pg_query/include/postgres/utils/guc_tables.h +6 -5
- data/ext/pg_query/include/postgres/utils/hsearch.h +2 -2
- data/ext/pg_query/include/postgres/utils/injection_point.h +44 -0
- data/ext/pg_query/include/postgres/utils/inval.h +1 -1
- data/ext/pg_query/include/postgres/utils/logtape.h +5 -5
- data/ext/pg_query/include/postgres/utils/lsyscache.h +6 -3
- data/ext/pg_query/include/postgres/utils/memdebug.h +1 -1
- data/ext/pg_query/include/postgres/utils/memutils.h +12 -5
- data/ext/pg_query/include/postgres/utils/memutils_internal.h +53 -13
- data/ext/pg_query/include/postgres/utils/memutils_memorychunk.h +25 -9
- data/ext/pg_query/include/postgres/utils/numeric.h +6 -1
- data/ext/pg_query/include/postgres/utils/palloc.h +1 -15
- data/ext/pg_query/include/postgres/utils/partcache.h +1 -1
- data/ext/pg_query/include/postgres/utils/pg_locale.h +8 -7
- data/ext/pg_query/include/postgres/utils/pgstat_internal.h +30 -17
- data/ext/pg_query/include/postgres/utils/plancache.h +5 -3
- data/ext/pg_query/include/postgres/utils/portal.h +10 -10
- data/ext/pg_query/include/postgres/utils/queryenvironment.h +2 -2
- data/ext/pg_query/include/postgres/utils/regproc.h +1 -1
- data/ext/pg_query/include/postgres/utils/rel.h +14 -15
- data/ext/pg_query/include/postgres/utils/relcache.h +2 -5
- data/ext/pg_query/include/postgres/utils/reltrigger.h +1 -1
- data/ext/pg_query/include/postgres/utils/resowner.h +90 -9
- data/ext/pg_query/include/postgres/utils/ruleutils.h +1 -1
- data/ext/pg_query/include/postgres/utils/sharedtuplestore.h +1 -1
- data/ext/pg_query/include/postgres/utils/snapmgr.h +1 -52
- data/ext/pg_query/include/postgres/utils/snapshot.h +2 -2
- data/ext/pg_query/include/postgres/utils/sortsupport.h +1 -1
- data/ext/pg_query/include/postgres/utils/syscache.h +7 -98
- data/ext/pg_query/include/postgres/utils/timeout.h +3 -2
- data/ext/pg_query/include/postgres/utils/timestamp.h +1 -1
- data/ext/pg_query/include/postgres/utils/tuplesort.h +36 -9
- data/ext/pg_query/include/postgres/utils/tuplestore.h +2 -5
- data/ext/pg_query/include/postgres/utils/typcache.h +2 -1
- data/ext/pg_query/include/postgres/utils/varlena.h +1 -1
- data/ext/pg_query/include/postgres/utils/wait_event.h +28 -214
- data/ext/pg_query/include/postgres/utils/wait_event_types.h +218 -0
- data/ext/pg_query/include/postgres/utils/xml.h +4 -4
- data/ext/pg_query/include/postgres/varatt.h +1 -1
- data/ext/pg_query/include/protobuf/pg_query.pb-c.h +1546 -792
- data/ext/pg_query/include/protobuf/pg_query.pb.h +58365 -46595
- data/ext/pg_query/pg_query.pb-c.c +6598 -3739
- data/ext/pg_query/pg_query_normalize.c +42 -1
- data/ext/pg_query/pg_query_outfuncs_json.c +3 -1
- data/ext/pg_query/pg_query_parse_plpgsql.c +12 -13
- data/ext/pg_query/pg_query_readfuncs_protobuf.c +2 -2
- data/ext/pg_query/pg_query_scan.c +1 -1
- data/ext/pg_query/postgres_deparse.c +601 -172
- data/ext/pg_query/src_backend_catalog_namespace.c +241 -66
- data/ext/pg_query/src_backend_catalog_pg_proc.c +1 -3
- data/ext/pg_query/src_backend_commands_define.c +2 -3
- data/ext/pg_query/src_backend_nodes_bitmapset.c +137 -94
- data/ext/pg_query/src_backend_nodes_copyfuncs.c +1 -1
- data/ext/pg_query/src_backend_nodes_equalfuncs.c +1 -1
- data/ext/pg_query/src_backend_nodes_extensible.c +1 -1
- data/ext/pg_query/src_backend_nodes_list.c +3 -7
- data/ext/pg_query/src_backend_nodes_makefuncs.c +59 -20
- data/ext/pg_query/src_backend_nodes_nodeFuncs.c +109 -2
- data/ext/pg_query/src_backend_nodes_value.c +1 -1
- data/ext/pg_query/src_backend_parser_gram.c +34491 -32136
- data/ext/pg_query/src_backend_parser_parser.c +8 -8
- data/ext/pg_query/src_backend_parser_scan.c +5637 -3028
- data/ext/pg_query/src_backend_parser_scansup.c +2 -1
- data/ext/pg_query/src_backend_storage_ipc_ipc.c +1 -1
- data/ext/pg_query/src_backend_tcop_postgres.c +34 -10
- data/ext/pg_query/src_backend_utils_activity_pgstat_database.c +2 -2
- data/ext/pg_query/src_backend_utils_adt_datum.c +8 -6
- data/ext/pg_query/src_backend_utils_adt_expandeddatum.c +1 -1
- data/ext/pg_query/src_backend_utils_adt_format_type.c +1 -1
- data/ext/pg_query/src_backend_utils_adt_numutils.c +4 -5
- data/ext/pg_query/src_backend_utils_adt_ruleutils.c +101 -28
- data/ext/pg_query/src_backend_utils_error_assert.c +1 -1
- data/ext/pg_query/src_backend_utils_error_elog.c +47 -42
- data/ext/pg_query/src_backend_utils_fmgr_fmgr.c +4 -2
- data/ext/pg_query/src_backend_utils_init_globals.c +15 -3
- data/ext/pg_query/src_backend_utils_mb_mbutils.c +11 -18
- data/ext/pg_query/src_backend_utils_misc_guc_tables.c +16 -6
- data/ext/pg_query/src_backend_utils_mmgr_alignedalloc.c +8 -5
- data/ext/pg_query/src_backend_utils_mmgr_aset.c +308 -238
- data/ext/pg_query/src_backend_utils_mmgr_bump.c +728 -0
- data/ext/pg_query/src_backend_utils_mmgr_generation.c +273 -197
- data/ext/pg_query/src_backend_utils_mmgr_mcxt.c +270 -215
- data/ext/pg_query/src_backend_utils_mmgr_slab.c +154 -96
- data/ext/pg_query/src_common_encnames.c +43 -44
- data/ext/pg_query/src_common_hashfn.c +1 -1
- data/ext/pg_query/src_common_keywords.c +1 -1
- data/ext/pg_query/src_common_kwlist_d.h +511 -466
- data/ext/pg_query/src_common_kwlookup.c +1 -1
- data/ext/pg_query/src_common_psprintf.c +3 -3
- data/ext/pg_query/src_common_stringinfo.c +18 -1
- data/ext/pg_query/src_common_wchar.c +92 -109
- data/ext/pg_query/src_pl_plpgsql_src_pl_comp.c +99 -5
- data/ext/pg_query/src_pl_plpgsql_src_pl_funcs.c +1 -1
- data/ext/pg_query/src_pl_plpgsql_src_pl_gram.c +242 -143
- data/ext/pg_query/src_pl_plpgsql_src_pl_handler.c +1 -1
- data/ext/pg_query/src_pl_plpgsql_src_pl_reserved_kwlist_d.h +1 -1
- data/ext/pg_query/src_pl_plpgsql_src_pl_scanner.c +19 -1
- data/ext/pg_query/src_pl_plpgsql_src_pl_unreserved_kwlist_d.h +1 -1
- data/ext/pg_query/src_port_pg_bitutils.c +173 -28
- data/ext/pg_query/src_port_pgstrcasecmp.c +29 -1
- data/ext/pg_query/src_port_snprintf.c +15 -18
- data/ext/pg_query/src_port_strerror.c +1 -3
- data/ext/pg_query/src_port_strlcpy.c +1 -1
- data/lib/pg_query/fingerprint.rb +3 -5
- data/lib/pg_query/param_refs.rb +2 -2
- data/lib/pg_query/parse.rb +5 -7
- data/lib/pg_query/parse_error.rb +1 -0
- data/lib/pg_query/pg_query_pb.rb +27 -25
- data/lib/pg_query/scan.rb +1 -0
- data/lib/pg_query/treewalker.rb +38 -15
- data/lib/pg_query/truncate.rb +18 -20
- data/lib/pg_query/version.rb +1 -1
- metadata +31 -82
- data/ext/pg_query/include/postgres/storage/backendid.h +0 -37
- data/ext/pg_query/include/postgres/storage/sinvaladt.h +0 -45
- data/ext/pg_query/pg_query_ruby_freebsd.sym +0 -2
- data/ext/pg_query/src_backend_nodes_nodes.c +0 -38
- /data/ext/pg_query/{pg_query_ruby.sym → ext_symbols.sym} +0 -0
@@ -3,7 +3,7 @@
|
|
3
3
|
* equalfuncs.funcs.c
|
4
4
|
* Generated node infrastructure code
|
5
5
|
*
|
6
|
-
* Portions Copyright (c) 1996-
|
6
|
+
* Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
|
7
7
|
* Portions Copyright (c) 1994, Regents of the University of California
|
8
8
|
*
|
9
9
|
* NOTES
|
@@ -64,6 +64,7 @@ _equalRangeVar(const RangeVar *a, const RangeVar *b)
|
|
64
64
|
static bool
|
65
65
|
_equalTableFunc(const TableFunc *a, const TableFunc *b)
|
66
66
|
{
|
67
|
+
COMPARE_SCALAR_FIELD(functype);
|
67
68
|
COMPARE_NODE_FIELD(ns_uris);
|
68
69
|
COMPARE_NODE_FIELD(ns_names);
|
69
70
|
COMPARE_NODE_FIELD(docexpr);
|
@@ -74,7 +75,10 @@ _equalTableFunc(const TableFunc *a, const TableFunc *b)
|
|
74
75
|
COMPARE_NODE_FIELD(colcollations);
|
75
76
|
COMPARE_NODE_FIELD(colexprs);
|
76
77
|
COMPARE_NODE_FIELD(coldefexprs);
|
78
|
+
COMPARE_NODE_FIELD(colvalexprs);
|
79
|
+
COMPARE_NODE_FIELD(passingvalexprs);
|
77
80
|
COMPARE_BITMAPSET_FIELD(notnulls);
|
81
|
+
COMPARE_NODE_FIELD(plan);
|
78
82
|
COMPARE_SCALAR_FIELD(ordinalitycol);
|
79
83
|
COMPARE_LOCATION_FIELD(location);
|
80
84
|
|
@@ -168,6 +172,7 @@ _equalWindowFunc(const WindowFunc *a, const WindowFunc *b)
|
|
168
172
|
COMPARE_SCALAR_FIELD(inputcollid);
|
169
173
|
COMPARE_NODE_FIELD(args);
|
170
174
|
COMPARE_NODE_FIELD(aggfilter);
|
175
|
+
COMPARE_NODE_FIELD(runCondition);
|
171
176
|
COMPARE_SCALAR_FIELD(winref);
|
172
177
|
COMPARE_SCALAR_FIELD(winstar);
|
173
178
|
COMPARE_SCALAR_FIELD(winagg);
|
@@ -176,6 +181,27 @@ _equalWindowFunc(const WindowFunc *a, const WindowFunc *b)
|
|
176
181
|
return true;
|
177
182
|
}
|
178
183
|
|
184
|
+
static bool
|
185
|
+
_equalWindowFuncRunCondition(const WindowFuncRunCondition *a, const WindowFuncRunCondition *b)
|
186
|
+
{
|
187
|
+
COMPARE_SCALAR_FIELD(opno);
|
188
|
+
COMPARE_SCALAR_FIELD(inputcollid);
|
189
|
+
COMPARE_SCALAR_FIELD(wfunc_left);
|
190
|
+
COMPARE_NODE_FIELD(arg);
|
191
|
+
|
192
|
+
return true;
|
193
|
+
}
|
194
|
+
|
195
|
+
static bool
|
196
|
+
_equalMergeSupportFunc(const MergeSupportFunc *a, const MergeSupportFunc *b)
|
197
|
+
{
|
198
|
+
COMPARE_SCALAR_FIELD(msftype);
|
199
|
+
COMPARE_SCALAR_FIELD(msfcollid);
|
200
|
+
COMPARE_LOCATION_FIELD(location);
|
201
|
+
|
202
|
+
return true;
|
203
|
+
}
|
204
|
+
|
179
205
|
static bool
|
180
206
|
_equalSubscriptingRef(const SubscriptingRef *a, const SubscriptingRef *b)
|
181
207
|
{
|
@@ -596,6 +622,70 @@ _equalJsonIsPredicate(const JsonIsPredicate *a, const JsonIsPredicate *b)
|
|
596
622
|
return true;
|
597
623
|
}
|
598
624
|
|
625
|
+
static bool
|
626
|
+
_equalJsonBehavior(const JsonBehavior *a, const JsonBehavior *b)
|
627
|
+
{
|
628
|
+
COMPARE_SCALAR_FIELD(btype);
|
629
|
+
COMPARE_NODE_FIELD(expr);
|
630
|
+
COMPARE_SCALAR_FIELD(coerce);
|
631
|
+
COMPARE_LOCATION_FIELD(location);
|
632
|
+
|
633
|
+
return true;
|
634
|
+
}
|
635
|
+
|
636
|
+
static bool
|
637
|
+
_equalJsonExpr(const JsonExpr *a, const JsonExpr *b)
|
638
|
+
{
|
639
|
+
COMPARE_SCALAR_FIELD(op);
|
640
|
+
COMPARE_STRING_FIELD(column_name);
|
641
|
+
COMPARE_NODE_FIELD(formatted_expr);
|
642
|
+
COMPARE_NODE_FIELD(format);
|
643
|
+
COMPARE_NODE_FIELD(path_spec);
|
644
|
+
COMPARE_NODE_FIELD(returning);
|
645
|
+
COMPARE_NODE_FIELD(passing_names);
|
646
|
+
COMPARE_NODE_FIELD(passing_values);
|
647
|
+
COMPARE_NODE_FIELD(on_empty);
|
648
|
+
COMPARE_NODE_FIELD(on_error);
|
649
|
+
COMPARE_SCALAR_FIELD(use_io_coercion);
|
650
|
+
COMPARE_SCALAR_FIELD(use_json_coercion);
|
651
|
+
COMPARE_SCALAR_FIELD(wrapper);
|
652
|
+
COMPARE_SCALAR_FIELD(omit_quotes);
|
653
|
+
COMPARE_SCALAR_FIELD(collation);
|
654
|
+
COMPARE_LOCATION_FIELD(location);
|
655
|
+
|
656
|
+
return true;
|
657
|
+
}
|
658
|
+
|
659
|
+
static bool
|
660
|
+
_equalJsonTablePath(const JsonTablePath *a, const JsonTablePath *b)
|
661
|
+
{
|
662
|
+
COMPARE_NODE_FIELD(value);
|
663
|
+
COMPARE_STRING_FIELD(name);
|
664
|
+
|
665
|
+
return true;
|
666
|
+
}
|
667
|
+
|
668
|
+
static bool
|
669
|
+
_equalJsonTablePathScan(const JsonTablePathScan *a, const JsonTablePathScan *b)
|
670
|
+
{
|
671
|
+
COMPARE_NODE_FIELD(path);
|
672
|
+
COMPARE_SCALAR_FIELD(errorOnError);
|
673
|
+
COMPARE_NODE_FIELD(child);
|
674
|
+
COMPARE_SCALAR_FIELD(colMin);
|
675
|
+
COMPARE_SCALAR_FIELD(colMax);
|
676
|
+
|
677
|
+
return true;
|
678
|
+
}
|
679
|
+
|
680
|
+
static bool
|
681
|
+
_equalJsonTableSiblingJoin(const JsonTableSiblingJoin *a, const JsonTableSiblingJoin *b)
|
682
|
+
{
|
683
|
+
COMPARE_NODE_FIELD(lplan);
|
684
|
+
COMPARE_NODE_FIELD(rplan);
|
685
|
+
|
686
|
+
return true;
|
687
|
+
}
|
688
|
+
|
599
689
|
static bool
|
600
690
|
_equalNullTest(const NullTest *a, const NullTest *b)
|
601
691
|
{
|
@@ -617,6 +707,19 @@ _equalBooleanTest(const BooleanTest *a, const BooleanTest *b)
|
|
617
707
|
return true;
|
618
708
|
}
|
619
709
|
|
710
|
+
static bool
|
711
|
+
_equalMergeAction(const MergeAction *a, const MergeAction *b)
|
712
|
+
{
|
713
|
+
COMPARE_SCALAR_FIELD(matchKind);
|
714
|
+
COMPARE_SCALAR_FIELD(commandType);
|
715
|
+
COMPARE_SCALAR_FIELD(override);
|
716
|
+
COMPARE_NODE_FIELD(qual);
|
717
|
+
COMPARE_NODE_FIELD(targetList);
|
718
|
+
COMPARE_NODE_FIELD(updateColnos);
|
719
|
+
|
720
|
+
return true;
|
721
|
+
}
|
722
|
+
|
620
723
|
static bool
|
621
724
|
_equalCoerceToDomain(const CoerceToDomain *a, const CoerceToDomain *b)
|
622
725
|
{
|
@@ -765,7 +868,8 @@ _equalQuery(const Query *a, const Query *b)
|
|
765
868
|
COMPARE_NODE_FIELD(rteperminfos);
|
766
869
|
COMPARE_NODE_FIELD(jointree);
|
767
870
|
COMPARE_NODE_FIELD(mergeActionList);
|
768
|
-
COMPARE_SCALAR_FIELD(
|
871
|
+
COMPARE_SCALAR_FIELD(mergeTargetRelation);
|
872
|
+
COMPARE_NODE_FIELD(mergeJoinCondition);
|
769
873
|
COMPARE_NODE_FIELD(targetList);
|
770
874
|
COMPARE_SCALAR_FIELD(override);
|
771
875
|
COMPARE_NODE_FIELD(onConflict);
|
@@ -785,7 +889,7 @@ _equalQuery(const Query *a, const Query *b)
|
|
785
889
|
COMPARE_NODE_FIELD(constraintDeps);
|
786
890
|
COMPARE_NODE_FIELD(withCheckOptions);
|
787
891
|
COMPARE_LOCATION_FIELD(stmt_location);
|
788
|
-
|
892
|
+
COMPARE_LOCATION_FIELD(stmt_len);
|
789
893
|
|
790
894
|
return true;
|
791
895
|
}
|
@@ -1160,6 +1264,13 @@ _equalPartitionRangeDatum(const PartitionRangeDatum *a, const PartitionRangeDatu
|
|
1160
1264
|
return true;
|
1161
1265
|
}
|
1162
1266
|
|
1267
|
+
static bool
|
1268
|
+
_equalSinglePartitionSpec(const SinglePartitionSpec *a, const SinglePartitionSpec *b)
|
1269
|
+
{
|
1270
|
+
|
1271
|
+
return true;
|
1272
|
+
}
|
1273
|
+
|
1163
1274
|
static bool
|
1164
1275
|
_equalPartitionCmd(const PartitionCmd *a, const PartitionCmd *b)
|
1165
1276
|
{
|
@@ -1173,12 +1284,15 @@ _equalPartitionCmd(const PartitionCmd *a, const PartitionCmd *b)
|
|
1173
1284
|
static bool
|
1174
1285
|
_equalRangeTblEntry(const RangeTblEntry *a, const RangeTblEntry *b)
|
1175
1286
|
{
|
1287
|
+
COMPARE_NODE_FIELD(alias);
|
1288
|
+
COMPARE_NODE_FIELD(eref);
|
1176
1289
|
COMPARE_SCALAR_FIELD(rtekind);
|
1177
1290
|
COMPARE_SCALAR_FIELD(relid);
|
1291
|
+
COMPARE_SCALAR_FIELD(inh);
|
1178
1292
|
COMPARE_SCALAR_FIELD(relkind);
|
1179
1293
|
COMPARE_SCALAR_FIELD(rellockmode);
|
1180
|
-
COMPARE_NODE_FIELD(tablesample);
|
1181
1294
|
COMPARE_SCALAR_FIELD(perminfoindex);
|
1295
|
+
COMPARE_NODE_FIELD(tablesample);
|
1182
1296
|
COMPARE_NODE_FIELD(subquery);
|
1183
1297
|
COMPARE_SCALAR_FIELD(security_barrier);
|
1184
1298
|
COMPARE_SCALAR_FIELD(jointype);
|
@@ -1199,10 +1313,7 @@ _equalRangeTblEntry(const RangeTblEntry *a, const RangeTblEntry *b)
|
|
1199
1313
|
COMPARE_NODE_FIELD(colcollations);
|
1200
1314
|
COMPARE_STRING_FIELD(enrname);
|
1201
1315
|
COMPARE_SCALAR_FIELD(enrtuples);
|
1202
|
-
COMPARE_NODE_FIELD(alias);
|
1203
|
-
COMPARE_NODE_FIELD(eref);
|
1204
1316
|
COMPARE_SCALAR_FIELD(lateral);
|
1205
|
-
COMPARE_SCALAR_FIELD(inh);
|
1206
1317
|
COMPARE_SCALAR_FIELD(inFromCl);
|
1207
1318
|
COMPARE_NODE_FIELD(securityQuals);
|
1208
1319
|
|
@@ -1291,7 +1402,6 @@ _equalWindowClause(const WindowClause *a, const WindowClause *b)
|
|
1291
1402
|
COMPARE_SCALAR_FIELD(frameOptions);
|
1292
1403
|
COMPARE_NODE_FIELD(startOffset);
|
1293
1404
|
COMPARE_NODE_FIELD(endOffset);
|
1294
|
-
COMPARE_NODE_FIELD(runCondition);
|
1295
1405
|
COMPARE_SCALAR_FIELD(startInRangeFunc);
|
1296
1406
|
COMPARE_SCALAR_FIELD(endInRangeFunc);
|
1297
1407
|
COMPARE_SCALAR_FIELD(inRangeColl);
|
@@ -1398,7 +1508,7 @@ _equalCommonTableExpr(const CommonTableExpr *a, const CommonTableExpr *b)
|
|
1398
1508
|
static bool
|
1399
1509
|
_equalMergeWhenClause(const MergeWhenClause *a, const MergeWhenClause *b)
|
1400
1510
|
{
|
1401
|
-
COMPARE_SCALAR_FIELD(
|
1511
|
+
COMPARE_SCALAR_FIELD(matchKind);
|
1402
1512
|
COMPARE_SCALAR_FIELD(commandType);
|
1403
1513
|
COMPARE_SCALAR_FIELD(override);
|
1404
1514
|
COMPARE_NODE_FIELD(condition);
|
@@ -1409,33 +1519,91 @@ _equalMergeWhenClause(const MergeWhenClause *a, const MergeWhenClause *b)
|
|
1409
1519
|
}
|
1410
1520
|
|
1411
1521
|
static bool
|
1412
|
-
|
1522
|
+
_equalTriggerTransition(const TriggerTransition *a, const TriggerTransition *b)
|
1413
1523
|
{
|
1414
|
-
|
1415
|
-
COMPARE_SCALAR_FIELD(
|
1416
|
-
COMPARE_SCALAR_FIELD(
|
1417
|
-
COMPARE_NODE_FIELD(qual);
|
1418
|
-
COMPARE_NODE_FIELD(targetList);
|
1419
|
-
COMPARE_NODE_FIELD(updateColnos);
|
1524
|
+
COMPARE_STRING_FIELD(name);
|
1525
|
+
COMPARE_SCALAR_FIELD(isNew);
|
1526
|
+
COMPARE_SCALAR_FIELD(isTable);
|
1420
1527
|
|
1421
1528
|
return true;
|
1422
1529
|
}
|
1423
1530
|
|
1424
1531
|
static bool
|
1425
|
-
|
1532
|
+
_equalJsonOutput(const JsonOutput *a, const JsonOutput *b)
|
1533
|
+
{
|
1534
|
+
COMPARE_NODE_FIELD(typeName);
|
1535
|
+
COMPARE_NODE_FIELD(returning);
|
1536
|
+
|
1537
|
+
return true;
|
1538
|
+
}
|
1539
|
+
|
1540
|
+
static bool
|
1541
|
+
_equalJsonArgument(const JsonArgument *a, const JsonArgument *b)
|
1426
1542
|
{
|
1543
|
+
COMPARE_NODE_FIELD(val);
|
1427
1544
|
COMPARE_STRING_FIELD(name);
|
1428
|
-
COMPARE_SCALAR_FIELD(isNew);
|
1429
|
-
COMPARE_SCALAR_FIELD(isTable);
|
1430
1545
|
|
1431
1546
|
return true;
|
1432
1547
|
}
|
1433
1548
|
|
1434
1549
|
static bool
|
1435
|
-
|
1550
|
+
_equalJsonFuncExpr(const JsonFuncExpr *a, const JsonFuncExpr *b)
|
1551
|
+
{
|
1552
|
+
COMPARE_SCALAR_FIELD(op);
|
1553
|
+
COMPARE_STRING_FIELD(column_name);
|
1554
|
+
COMPARE_NODE_FIELD(context_item);
|
1555
|
+
COMPARE_NODE_FIELD(pathspec);
|
1556
|
+
COMPARE_NODE_FIELD(passing);
|
1557
|
+
COMPARE_NODE_FIELD(output);
|
1558
|
+
COMPARE_NODE_FIELD(on_empty);
|
1559
|
+
COMPARE_NODE_FIELD(on_error);
|
1560
|
+
COMPARE_SCALAR_FIELD(wrapper);
|
1561
|
+
COMPARE_SCALAR_FIELD(quotes);
|
1562
|
+
COMPARE_LOCATION_FIELD(location);
|
1563
|
+
|
1564
|
+
return true;
|
1565
|
+
}
|
1566
|
+
|
1567
|
+
static bool
|
1568
|
+
_equalJsonTablePathSpec(const JsonTablePathSpec *a, const JsonTablePathSpec *b)
|
1569
|
+
{
|
1570
|
+
COMPARE_NODE_FIELD(string);
|
1571
|
+
COMPARE_STRING_FIELD(name);
|
1572
|
+
COMPARE_LOCATION_FIELD(name_location);
|
1573
|
+
COMPARE_LOCATION_FIELD(location);
|
1574
|
+
|
1575
|
+
return true;
|
1576
|
+
}
|
1577
|
+
|
1578
|
+
static bool
|
1579
|
+
_equalJsonTable(const JsonTable *a, const JsonTable *b)
|
1436
1580
|
{
|
1581
|
+
COMPARE_NODE_FIELD(context_item);
|
1582
|
+
COMPARE_NODE_FIELD(pathspec);
|
1583
|
+
COMPARE_NODE_FIELD(passing);
|
1584
|
+
COMPARE_NODE_FIELD(columns);
|
1585
|
+
COMPARE_NODE_FIELD(on_error);
|
1586
|
+
COMPARE_NODE_FIELD(alias);
|
1587
|
+
COMPARE_SCALAR_FIELD(lateral);
|
1588
|
+
COMPARE_LOCATION_FIELD(location);
|
1589
|
+
|
1590
|
+
return true;
|
1591
|
+
}
|
1592
|
+
|
1593
|
+
static bool
|
1594
|
+
_equalJsonTableColumn(const JsonTableColumn *a, const JsonTableColumn *b)
|
1595
|
+
{
|
1596
|
+
COMPARE_SCALAR_FIELD(coltype);
|
1597
|
+
COMPARE_STRING_FIELD(name);
|
1437
1598
|
COMPARE_NODE_FIELD(typeName);
|
1438
|
-
COMPARE_NODE_FIELD(
|
1599
|
+
COMPARE_NODE_FIELD(pathspec);
|
1600
|
+
COMPARE_NODE_FIELD(format);
|
1601
|
+
COMPARE_SCALAR_FIELD(wrapper);
|
1602
|
+
COMPARE_SCALAR_FIELD(quotes);
|
1603
|
+
COMPARE_NODE_FIELD(columns);
|
1604
|
+
COMPARE_NODE_FIELD(on_empty);
|
1605
|
+
COMPARE_NODE_FIELD(on_error);
|
1606
|
+
COMPARE_LOCATION_FIELD(location);
|
1439
1607
|
|
1440
1608
|
return true;
|
1441
1609
|
}
|
@@ -1449,6 +1617,37 @@ _equalJsonKeyValue(const JsonKeyValue *a, const JsonKeyValue *b)
|
|
1449
1617
|
return true;
|
1450
1618
|
}
|
1451
1619
|
|
1620
|
+
static bool
|
1621
|
+
_equalJsonParseExpr(const JsonParseExpr *a, const JsonParseExpr *b)
|
1622
|
+
{
|
1623
|
+
COMPARE_NODE_FIELD(expr);
|
1624
|
+
COMPARE_NODE_FIELD(output);
|
1625
|
+
COMPARE_SCALAR_FIELD(unique_keys);
|
1626
|
+
COMPARE_LOCATION_FIELD(location);
|
1627
|
+
|
1628
|
+
return true;
|
1629
|
+
}
|
1630
|
+
|
1631
|
+
static bool
|
1632
|
+
_equalJsonScalarExpr(const JsonScalarExpr *a, const JsonScalarExpr *b)
|
1633
|
+
{
|
1634
|
+
COMPARE_NODE_FIELD(expr);
|
1635
|
+
COMPARE_NODE_FIELD(output);
|
1636
|
+
COMPARE_LOCATION_FIELD(location);
|
1637
|
+
|
1638
|
+
return true;
|
1639
|
+
}
|
1640
|
+
|
1641
|
+
static bool
|
1642
|
+
_equalJsonSerializeExpr(const JsonSerializeExpr *a, const JsonSerializeExpr *b)
|
1643
|
+
{
|
1644
|
+
COMPARE_NODE_FIELD(expr);
|
1645
|
+
COMPARE_NODE_FIELD(output);
|
1646
|
+
COMPARE_LOCATION_FIELD(location);
|
1647
|
+
|
1648
|
+
return true;
|
1649
|
+
}
|
1650
|
+
|
1452
1651
|
static bool
|
1453
1652
|
_equalJsonObjectConstructor(const JsonObjectConstructor *a, const JsonObjectConstructor *b)
|
1454
1653
|
{
|
@@ -1522,7 +1721,7 @@ _equalRawStmt(const RawStmt *a, const RawStmt *b)
|
|
1522
1721
|
{
|
1523
1722
|
COMPARE_NODE_FIELD(stmt);
|
1524
1723
|
COMPARE_LOCATION_FIELD(stmt_location);
|
1525
|
-
|
1724
|
+
COMPARE_LOCATION_FIELD(stmt_len);
|
1526
1725
|
|
1527
1726
|
return true;
|
1528
1727
|
}
|
@@ -1573,6 +1772,7 @@ _equalMergeStmt(const MergeStmt *a, const MergeStmt *b)
|
|
1573
1772
|
COMPARE_NODE_FIELD(sourceRelation);
|
1574
1773
|
COMPARE_NODE_FIELD(joinCondition);
|
1575
1774
|
COMPARE_NODE_FIELD(mergeWhenClauses);
|
1775
|
+
COMPARE_NODE_FIELD(returningList);
|
1576
1776
|
COMPARE_NODE_FIELD(withClause);
|
1577
1777
|
|
1578
1778
|
return true;
|
@@ -1825,11 +2025,13 @@ _equalConstraint(const Constraint *a, const Constraint *b)
|
|
1825
2025
|
COMPARE_STRING_FIELD(conname);
|
1826
2026
|
COMPARE_SCALAR_FIELD(deferrable);
|
1827
2027
|
COMPARE_SCALAR_FIELD(initdeferred);
|
1828
|
-
|
2028
|
+
COMPARE_SCALAR_FIELD(skip_validation);
|
2029
|
+
COMPARE_SCALAR_FIELD(initially_valid);
|
1829
2030
|
COMPARE_SCALAR_FIELD(is_no_inherit);
|
1830
2031
|
COMPARE_NODE_FIELD(raw_expr);
|
1831
2032
|
COMPARE_STRING_FIELD(cooked_expr);
|
1832
2033
|
COMPARE_SCALAR_FIELD(generated_when);
|
2034
|
+
COMPARE_SCALAR_FIELD(inhcount);
|
1833
2035
|
COMPARE_SCALAR_FIELD(nulls_not_distinct);
|
1834
2036
|
COMPARE_NODE_FIELD(keys);
|
1835
2037
|
COMPARE_NODE_FIELD(including);
|
@@ -1849,8 +2051,7 @@ _equalConstraint(const Constraint *a, const Constraint *b)
|
|
1849
2051
|
COMPARE_NODE_FIELD(fk_del_set_cols);
|
1850
2052
|
COMPARE_NODE_FIELD(old_conpfeqop);
|
1851
2053
|
COMPARE_SCALAR_FIELD(old_pktable_oid);
|
1852
|
-
|
1853
|
-
COMPARE_SCALAR_FIELD(initially_valid);
|
2054
|
+
COMPARE_LOCATION_FIELD(location);
|
1854
2055
|
|
1855
2056
|
return true;
|
1856
2057
|
}
|
@@ -2390,7 +2591,7 @@ static bool
|
|
2390
2591
|
_equalAlterStatsStmt(const AlterStatsStmt *a, const AlterStatsStmt *b)
|
2391
2592
|
{
|
2392
2593
|
COMPARE_NODE_FIELD(defnames);
|
2393
|
-
|
2594
|
+
COMPARE_NODE_FIELD(stxstattarget);
|
2394
2595
|
COMPARE_SCALAR_FIELD(missing_ok);
|
2395
2596
|
|
2396
2597
|
return true;
|
@@ -2564,6 +2765,7 @@ _equalTransactionStmt(const TransactionStmt *a, const TransactionStmt *b)
|
|
2564
2765
|
COMPARE_STRING_FIELD(savepoint_name);
|
2565
2766
|
COMPARE_STRING_FIELD(gid);
|
2566
2767
|
COMPARE_SCALAR_FIELD(chain);
|
2768
|
+
COMPARE_LOCATION_FIELD(location);
|
2567
2769
|
|
2568
2770
|
return true;
|
2569
2771
|
}
|
@@ -2847,6 +3049,8 @@ static bool
|
|
2847
3049
|
_equalDeallocateStmt(const DeallocateStmt *a, const DeallocateStmt *b)
|
2848
3050
|
{
|
2849
3051
|
COMPARE_STRING_FIELD(name);
|
3052
|
+
COMPARE_SCALAR_FIELD(isall);
|
3053
|
+
COMPARE_LOCATION_FIELD(location);
|
2850
3054
|
|
2851
3055
|
return true;
|
2852
3056
|
}
|
@@ -2980,6 +3184,15 @@ _equalPathKey(const PathKey *a, const PathKey *b)
|
|
2980
3184
|
return true;
|
2981
3185
|
}
|
2982
3186
|
|
3187
|
+
static bool
|
3188
|
+
_equalGroupByOrdering(const GroupByOrdering *a, const GroupByOrdering *b)
|
3189
|
+
{
|
3190
|
+
COMPARE_NODE_FIELD(pathkeys);
|
3191
|
+
COMPARE_NODE_FIELD(clauses);
|
3192
|
+
|
3193
|
+
return true;
|
3194
|
+
}
|
3195
|
+
|
2983
3196
|
static bool
|
2984
3197
|
_equalRestrictInfo(const RestrictInfo *a, const RestrictInfo *b)
|
2985
3198
|
{
|
@@ -3,7 +3,7 @@
|
|
3
3
|
* equalfuncs.switch.c
|
4
4
|
* Generated node infrastructure code
|
5
5
|
*
|
6
|
-
* Portions Copyright (c) 1996-
|
6
|
+
* Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
|
7
7
|
* Portions Copyright (c) 1994, Regents of the University of California
|
8
8
|
*
|
9
9
|
* NOTES
|
@@ -45,6 +45,12 @@
|
|
45
45
|
case T_WindowFunc:
|
46
46
|
retval = _equalWindowFunc(a, b);
|
47
47
|
break;
|
48
|
+
case T_WindowFuncRunCondition:
|
49
|
+
retval = _equalWindowFuncRunCondition(a, b);
|
50
|
+
break;
|
51
|
+
case T_MergeSupportFunc:
|
52
|
+
retval = _equalMergeSupportFunc(a, b);
|
53
|
+
break;
|
48
54
|
case T_SubscriptingRef:
|
49
55
|
retval = _equalSubscriptingRef(a, b);
|
50
56
|
break;
|
@@ -144,12 +150,30 @@
|
|
144
150
|
case T_JsonIsPredicate:
|
145
151
|
retval = _equalJsonIsPredicate(a, b);
|
146
152
|
break;
|
153
|
+
case T_JsonBehavior:
|
154
|
+
retval = _equalJsonBehavior(a, b);
|
155
|
+
break;
|
156
|
+
case T_JsonExpr:
|
157
|
+
retval = _equalJsonExpr(a, b);
|
158
|
+
break;
|
159
|
+
case T_JsonTablePath:
|
160
|
+
retval = _equalJsonTablePath(a, b);
|
161
|
+
break;
|
162
|
+
case T_JsonTablePathScan:
|
163
|
+
retval = _equalJsonTablePathScan(a, b);
|
164
|
+
break;
|
165
|
+
case T_JsonTableSiblingJoin:
|
166
|
+
retval = _equalJsonTableSiblingJoin(a, b);
|
167
|
+
break;
|
147
168
|
case T_NullTest:
|
148
169
|
retval = _equalNullTest(a, b);
|
149
170
|
break;
|
150
171
|
case T_BooleanTest:
|
151
172
|
retval = _equalBooleanTest(a, b);
|
152
173
|
break;
|
174
|
+
case T_MergeAction:
|
175
|
+
retval = _equalMergeAction(a, b);
|
176
|
+
break;
|
153
177
|
case T_CoerceToDomain:
|
154
178
|
retval = _equalCoerceToDomain(a, b);
|
155
179
|
break;
|
@@ -282,6 +306,9 @@
|
|
282
306
|
case T_PartitionRangeDatum:
|
283
307
|
retval = _equalPartitionRangeDatum(a, b);
|
284
308
|
break;
|
309
|
+
case T_SinglePartitionSpec:
|
310
|
+
retval = _equalSinglePartitionSpec(a, b);
|
311
|
+
break;
|
285
312
|
case T_PartitionCmd:
|
286
313
|
retval = _equalPartitionCmd(a, b);
|
287
314
|
break;
|
@@ -333,18 +360,39 @@
|
|
333
360
|
case T_MergeWhenClause:
|
334
361
|
retval = _equalMergeWhenClause(a, b);
|
335
362
|
break;
|
336
|
-
case T_MergeAction:
|
337
|
-
retval = _equalMergeAction(a, b);
|
338
|
-
break;
|
339
363
|
case T_TriggerTransition:
|
340
364
|
retval = _equalTriggerTransition(a, b);
|
341
365
|
break;
|
342
366
|
case T_JsonOutput:
|
343
367
|
retval = _equalJsonOutput(a, b);
|
344
368
|
break;
|
369
|
+
case T_JsonArgument:
|
370
|
+
retval = _equalJsonArgument(a, b);
|
371
|
+
break;
|
372
|
+
case T_JsonFuncExpr:
|
373
|
+
retval = _equalJsonFuncExpr(a, b);
|
374
|
+
break;
|
375
|
+
case T_JsonTablePathSpec:
|
376
|
+
retval = _equalJsonTablePathSpec(a, b);
|
377
|
+
break;
|
378
|
+
case T_JsonTable:
|
379
|
+
retval = _equalJsonTable(a, b);
|
380
|
+
break;
|
381
|
+
case T_JsonTableColumn:
|
382
|
+
retval = _equalJsonTableColumn(a, b);
|
383
|
+
break;
|
345
384
|
case T_JsonKeyValue:
|
346
385
|
retval = _equalJsonKeyValue(a, b);
|
347
386
|
break;
|
387
|
+
case T_JsonParseExpr:
|
388
|
+
retval = _equalJsonParseExpr(a, b);
|
389
|
+
break;
|
390
|
+
case T_JsonScalarExpr:
|
391
|
+
retval = _equalJsonScalarExpr(a, b);
|
392
|
+
break;
|
393
|
+
case T_JsonSerializeExpr:
|
394
|
+
retval = _equalJsonSerializeExpr(a, b);
|
395
|
+
break;
|
348
396
|
case T_JsonObjectConstructor:
|
349
397
|
retval = _equalJsonObjectConstructor(a, b);
|
350
398
|
break;
|
@@ -747,6 +795,9 @@
|
|
747
795
|
case T_PathKey:
|
748
796
|
retval = _equalPathKey(a, b);
|
749
797
|
break;
|
798
|
+
case T_GroupByOrdering:
|
799
|
+
retval = _equalGroupByOrdering(a, b);
|
800
|
+
break;
|
750
801
|
case T_RestrictInfo:
|
751
802
|
retval = _equalRestrictInfo(a, b);
|
752
803
|
break;
|
@@ -5,7 +5,7 @@
|
|
5
5
|
* and related modules.
|
6
6
|
*
|
7
7
|
*
|
8
|
-
* Portions Copyright (c) 1996-
|
8
|
+
* Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
|
9
9
|
* Portions Copyright (c) 1994, Regents of the University of California
|
10
10
|
*
|
11
11
|
* src/include/executor/execdesc.h
|
@@ -48,7 +48,7 @@ typedef struct QueryDesc
|
|
48
48
|
EState *estate; /* executor's query-wide state */
|
49
49
|
PlanState *planstate; /* tree of per-plan-node state */
|
50
50
|
|
51
|
-
/* This field is set by
|
51
|
+
/* This field is set by ExecutePlan */
|
52
52
|
bool already_executed; /* true if previously executed */
|
53
53
|
|
54
54
|
/* This is always set NULL by the core system, but plugins can change it */
|
@@ -4,7 +4,7 @@
|
|
4
4
|
* support for the POSTGRES executor module
|
5
5
|
*
|
6
6
|
*
|
7
|
-
* Portions Copyright (c) 1996-
|
7
|
+
* Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
|
8
8
|
* Portions Copyright (c) 1994, Regents of the University of California
|
9
9
|
*
|
10
10
|
* src/include/executor/executor.h
|
@@ -210,7 +210,8 @@ extern void standard_ExecutorEnd(QueryDesc *queryDesc);
|
|
210
210
|
extern void ExecutorRewind(QueryDesc *queryDesc);
|
211
211
|
extern bool ExecCheckPermissions(List *rangeTable,
|
212
212
|
List *rteperminfos, bool ereport_on_violation);
|
213
|
-
extern void CheckValidResultRel(ResultRelInfo *resultRelInfo, CmdType operation
|
213
|
+
extern void CheckValidResultRel(ResultRelInfo *resultRelInfo, CmdType operation,
|
214
|
+
List *mergeActions);
|
214
215
|
extern void InitResultRelInfo(ResultRelInfo *resultRelInfo,
|
215
216
|
Relation resultRelationDesc,
|
216
217
|
Index resultRelationIndex,
|
@@ -509,7 +510,7 @@ typedef struct TupOutputState
|
|
509
510
|
extern TupOutputState *begin_tup_output_tupdesc(DestReceiver *dest,
|
510
511
|
TupleDesc tupdesc,
|
511
512
|
const TupleTableSlotOps *tts_ops);
|
512
|
-
extern void do_tup_output(TupOutputState *tstate, Datum *values, bool *isnull);
|
513
|
+
extern void do_tup_output(TupOutputState *tstate, const Datum *values, const bool *isnull);
|
513
514
|
extern void do_text_output_multiline(TupOutputState *tstate, const char *txt);
|
514
515
|
extern void end_tup_output(TupOutputState *tstate);
|
515
516
|
|
@@ -569,7 +570,6 @@ extern void ExecAssignProjectionInfo(PlanState *planstate,
|
|
569
570
|
TupleDesc inputDesc);
|
570
571
|
extern void ExecConditionalAssignProjectionInfo(PlanState *planstate,
|
571
572
|
TupleDesc inputDesc, int varno);
|
572
|
-
extern void ExecFreeExprContext(PlanState *planstate);
|
573
573
|
extern void ExecAssignScanType(ScanState *scanstate, TupleDesc tupDesc);
|
574
574
|
extern void ExecCreateScanSlotFromOuterPlan(EState *estate,
|
575
575
|
ScanState *scanstate,
|
@@ -640,12 +640,13 @@ extern bool ExecCheckIndexConstraints(ResultRelInfo *resultRelInfo,
|
|
640
640
|
extern void check_exclusion_constraint(Relation heap, Relation index,
|
641
641
|
IndexInfo *indexInfo,
|
642
642
|
ItemPointer tupleid,
|
643
|
-
Datum *values, bool *isnull,
|
643
|
+
const Datum *values, const bool *isnull,
|
644
644
|
EState *estate, bool newIndex);
|
645
645
|
|
646
646
|
/*
|
647
647
|
* prototypes from functions in execReplication.c
|
648
648
|
*/
|
649
|
+
extern StrategyNumber get_equal_strategy_number_for_am(Oid am);
|
649
650
|
extern bool RelationFindReplTupleByIndex(Relation rel, Oid idxoid,
|
650
651
|
LockTupleMode lockmode,
|
651
652
|
TupleTableSlot *searchslot,
|
@@ -4,7 +4,7 @@
|
|
4
4
|
* Declarations for execution of SQL-language functions.
|
5
5
|
*
|
6
6
|
*
|
7
|
-
* Portions Copyright (c) 1996-
|
7
|
+
* Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
|
8
8
|
* Portions Copyright (c) 1994, Regents of the University of California
|
9
9
|
*
|
10
10
|
* src/include/executor/functions.h
|
@@ -47,6 +47,7 @@ extern void check_sql_fn_statements(List *queryTreeLists);
|
|
47
47
|
|
48
48
|
extern bool check_sql_fn_retval(List *queryTreeLists,
|
49
49
|
Oid rettype, TupleDesc rettupdesc,
|
50
|
+
char prokind,
|
50
51
|
bool insertDroppedCols,
|
51
52
|
List **resultTargetList);
|
52
53
|
|
@@ -4,7 +4,7 @@
|
|
4
4
|
* definitions for run-time statistics collection
|
5
5
|
*
|
6
6
|
*
|
7
|
-
* Copyright (c) 2001-
|
7
|
+
* Copyright (c) 2001-2024, PostgreSQL Global Development Group
|
8
8
|
*
|
9
9
|
* src/include/executor/instrument.h
|
10
10
|
*
|
@@ -33,8 +33,10 @@ typedef struct BufferUsage
|
|
33
33
|
int64 local_blks_written; /* # of local disk blocks written */
|
34
34
|
int64 temp_blks_read; /* # of temp blocks read */
|
35
35
|
int64 temp_blks_written; /* # of temp blocks written */
|
36
|
-
instr_time
|
37
|
-
instr_time
|
36
|
+
instr_time shared_blk_read_time; /* time spent reading shared blocks */
|
37
|
+
instr_time shared_blk_write_time; /* time spent writing shared blocks */
|
38
|
+
instr_time local_blk_read_time; /* time spent reading local blocks */
|
39
|
+
instr_time local_blk_write_time; /* time spent writing local blocks */
|
38
40
|
instr_time temp_blk_read_time; /* time spent reading temp blocks */
|
39
41
|
instr_time temp_blk_write_time; /* time spent writing temp blocks */
|
40
42
|
} BufferUsage;
|
@@ -3,7 +3,7 @@
|
|
3
3
|
* spi.h
|
4
4
|
* Server Programming Interface public declarations
|
5
5
|
*
|
6
|
-
* Portions Copyright (c) 1996-
|
6
|
+
* Portions Copyright (c) 1996-2024, PostgreSQL Global Development Group
|
7
7
|
* Portions Copyright (c) 1994, Regents of the University of California
|
8
8
|
*
|
9
9
|
* src/include/executor/spi.h
|
@@ -97,16 +97,10 @@ typedef struct _SPI_plan *SPIPlanPtr;
|
|
97
97
|
#define SPI_OK_REL_UNREGISTER 16
|
98
98
|
#define SPI_OK_TD_REGISTER 17
|
99
99
|
#define SPI_OK_MERGE 18
|
100
|
+
#define SPI_OK_MERGE_RETURNING 19
|
100
101
|
|
101
102
|
#define SPI_OPT_NONATOMIC (1 << 0)
|
102
103
|
|
103
|
-
/* These used to be functions, now just no-ops for backwards compatibility */
|
104
|
-
#define SPI_push() ((void) 0)
|
105
|
-
#define SPI_pop() ((void) 0)
|
106
|
-
#define SPI_push_conditional() false
|
107
|
-
#define SPI_pop_conditional(pushed) ((void) 0)
|
108
|
-
#define SPI_restore_connection() ((void) 0)
|
109
|
-
|
110
104
|
extern PGDLLIMPORT uint64 SPI_processed;
|
111
105
|
extern PGDLLIMPORT SPITupleTable *SPI_tuptable;
|
112
106
|
extern PGDLLIMPORT int SPI_result;
|