ProvSQL C/C++ API
Adding support for provenance and uncertainty management to PostgreSQL databases
Loading...
Searching...
No Matches
constants_t Struct Reference

Structure to store the value of various constants. More...

#include "provsql_utils.h"

Public Attributes

Oid OID_SCHEMA_PROVSQL
 OID of the provsql SCHEMA.
Oid OID_TYPE_GATE_TYPE
 OID of the provenance_gate TYPE.
Oid OID_TYPE_AGG_TOKEN
 OID of the agg_token TYPE.
Oid OID_TYPE_UUID
 OID of the uuid TYPE.
Oid OID_TYPE_UUID_ARRAY
 OID of the uuid[] TYPE.
Oid OID_TYPE_BOOL
 OID of the BOOL TYPE.
Oid OID_TYPE_INT
 OID of the INT TYPE.
Oid OID_TYPE_INT_ARRAY
 OID of the INT[] TYPE.
Oid OID_TYPE_FLOAT
 OID of the FLOAT TYPE.
Oid OID_TYPE_VARCHAR
 OID of the VARCHAR TYPE.
Oid OID_TYPE_TSTZMULTIRANGE
 OID of the tstzmultirange TYPE (PG14+, InvalidOid otherwise).
Oid OID_TYPE_NUMMULTIRANGE
 OID of the nummultirange TYPE (PG14+, InvalidOid otherwise).
Oid OID_TYPE_INT4MULTIRANGE
 OID of the int4multirange TYPE (PG14+, InvalidOid otherwise).
Oid OID_FUNCTION_ARRAY_AGG
 OID of the array_agg FUNCTION.
Oid OID_FUNCTION_PROVENANCE_PLUS
 OID of the provenance_plus FUNCTION.
Oid OID_FUNCTION_PROVENANCE_TIMES
 OID of the provenance_times FUNCTION.
Oid OID_FUNCTION_PROVENANCE_MONUS
 OID of the provenance_monus FUNCTION.
Oid OID_FUNCTION_PROVENANCE_PROJECT
 OID of the provenance_project FUNCTION.
Oid OID_FUNCTION_PROVENANCE_EQ
 OID of the provenance_eq FUNCTION.
Oid OID_FUNCTION_PROVENANCE_CMP
 OID of the provenance_cmp FUNCTION.
Oid OID_FUNCTION_PROVENANCE
 OID of the provenance FUNCTION.
Oid GATE_TYPE_TO_OID [nb_gate_types]
 Array of the OID of each provenance_gate ENUM value.
Oid OID_FUNCTION_PROVENANCE_DELTA
 OID of the provenance_delta FUNCTION.
Oid OID_FUNCTION_PROVENANCE_CMP_TIMES
 OID of the provenance_cmp_times FUNCTION.
Oid OID_FUNCTION_PROVENANCE_AGGREGATE
 OID of the provenance_aggregate FUNCTION.
Oid OID_FUNCTION_PROVENANCE_SEMIMOD
 OID of the provenance_semimod FUNCTION.
Oid OID_FUNCTION_GATE_ZERO
 OID of the provenance_zero FUNCTION.
Oid OID_FUNCTION_GATE_ONE
 OID of the provenance_one FUNCTION.
Oid OID_OPERATOR_NOT_EQUAL_UUID
 OID of the <> operator on UUIDs FUNCTION.
Oid OID_FUNCTION_NOT_EQUAL_UUID
 OID of the = operator on UUIDs FUNCTION.
Oid OID_FUNCTION_AGG_TOKEN_UUID
 OID of the agg_token_uuid FUNCTION.
Oid OID_FUNCTION_AGG_VALUE_GATE
 agg_value_gate(numeric) -> uuid
Oid OID_FUNCTION_GET_CHILDREN
 OID of the get_children FUNCTION.
Oid OID_FUNCTION_GET_EXTRA
 OID of the get_extra FUNCTION.
Oid OID_UNNEST
 OID of the unnest(anyarray) FUNCTION.
Oid OID_TYPE_RANDOM_VARIABLE
 OID of the random_variable TYPE.
Oid OID_TYPE_RANDOM_VARIABLE_ARRAY
 OID of the random_variable[] TYPE.
Oid OID_FUNCTION_RV_AGGREGATE_SEMIMOD
 OID of rv_aggregate_semimod(uuid, rv) -> rv: wraps a per-row argument as mixture(prov, rv, as_random(0)) (identity 0, for sum / avg-numerator).
Oid OID_FUNCTION_RV_AGGREGATE_SEMIMOD_ID
 OID of the 3-arg rv_aggregate_semimod(uuid, rv, float8): identity-parameterised wrap mixture(prov, rv, as_random(identity)) for product / max / min.
Oid OID_FUNCTION_RV_AGGREGATE_INDICATOR
 OID of rv_aggregate_indicator(uuid) -> rv: the avg denominator wrap mixture(prov, 1, 0).
Oid OID_FUNCTION_RV_AGGREGATE_INDICATOR_VALUED
 OID of rv_aggregate_indicator(uuid, rv) -> rv: NULL when the row's value is NULL (SQL NULL-skip for avg's count).
Oid OID_FUNCTION_RV_DIV
 OID of random_variable_div(rv, rv) -> rv: builds the avg num/denom division gate.
Oid OID_FUNCTION_CHOOSE
 OID of the choose(anyelement) aggregate (keeps the first non-NULL value); used to decorrelate scalar subqueries into a LEFT JOIN + GROUP BY.
Oid OID_FUNCTION_ASSUME_BOOLEAN
 OID of provsql.assume_boolean(uuid)->uuid.
Oid OID_FUNCTION_ANNOTATE
 OID of provsql.annotate(uuid,text)->uuid.
Oid OID_FUNCTION_INVERSION_FREE_KEY
 OID of provsql.inversion_free_key(text,text,int)->text.
Oid OID_FUNCTION_RV_CMP [6]
 OIDs of the random_variable_{eq,ne,le,lt,ge,gt} comparison procedure functions, indexed by the ComparisonOperator enum (EQ=0, NE=1, LE=2, LT=3, GE=4, GT=5; matches the order in src/Aggregation.h).
Oid OID_FUNCTION_COND
 OID of provsql.cond(uuid,uuid)->uuid.
Oid OID_FUNCTION_GIVEN
 OID of provsql.given(uuid)->uuid.
Oid OID_FUNCTION_RV_COND
 OID of provsql.random_variable_cond(random_variable,uuid).
Oid OID_FUNCTION_AGG_COND
 OID of provsql.agg_token_cond(agg_token,uuid): the conditioning constructor for the agg_token carrier the planner emits when rewriting the "SUM(x) | (predicate)" placeholder.
Oid OID_FUNCTION_REGULAR_INDICATOR
 OID of provsql.regular_indicator(boolean): the deterministic gate_one/gate_zero indicator the planner emits for an ordinary (regular-type) comparison appearing inside a mixed conditioning predicate.
Oid OID_FUNCTION_PROBABILITY_EVALUATE
 OID of the real provsql.probability_evaluate(uuid,text,text).
Oid OID_FUNCTION_PROBABILITY_PREDICATE
 OID of the probability(boolean,text,text) placeholder.
Oid OID_FUNCTION_RV_CASE
 OID of provsql.rv_case(uuid[])->random_variable.
Oid OID_FUNCTION_AGG_CASE
 OID of agg_case(uuid[]), the agg_token constructor the planner hook lowers an aggregate-carrier CASE into.
bool ok
 true if constants were loaded
Order-statistic constructors the planner lifts a builtin

GREATEST / LEAST over random_variable arguments into.

Oid OID_FUNCTION_RV_GREATEST
 provsql.greatest(VARIADIC random_variable[])
Oid OID_FUNCTION_RV_LEAST
 provsql.least(VARIADIC random_variable[])
Oid OID_AGG_SUM_RV
 OIDs of the RV-returning aggregates, keyed for the per-aggregate identity dispatch in make_rv_aggregate_expression (product / max / min bake their identity into the wrap; avg rewrites to sum/sum).
Oid OID_AGG_PRODUCT_RV
 provsql.product(random_variable)
Oid OID_AGG_AVG_RV
 provsql.avg(random_variable)
Oid OID_AGG_MAX_RV
 provsql.max(random_variable)
Oid OID_AGG_MIN_RV
 provsql.min(random_variable)
Oid OID_AGG_RV_SUM_OR_NULL
 provsql.rv_sum_or_null(random_variable): the avg-numerator sum, NULL on an empty group (so avg is NULL for an empty group after STRICT division)
Oid OID_AGG_COVAR_POP_RV
 SQL-standard statistic aggregates over random_variable rows and their internal indicator-carrying rewrite targets.
Oid OID_AGG_COVAR_SAMP_RV
 provsql.covar_samp(rv, rv)
Oid OID_AGG_CORR_RV
 provsql.corr(rv, rv)
Oid OID_AGG_STDDEV_POP_RV
 provsql.stddev_pop(rv)
Oid OID_AGG_STDDEV_SAMP_RV
 provsql.stddev_samp(rv)
Oid OID_AGG_PERCENTILE_CONT_RV
 provsql.percentile_cont(float8) WITHIN GROUP (ORDER BY rv)
Oid OID_AGG_RV_COVAR_POP_IMPL
 provsql.rv_covar_pop_impl(ind rv, x rv, y rv)
Oid OID_AGG_RV_COVAR_SAMP_IMPL
 provsql.rv_covar_samp_impl(ind rv, x rv, y rv)
Oid OID_AGG_RV_CORR_IMPL
 provsql.rv_corr_impl(ind rv, x rv, y rv)
Oid OID_AGG_RV_STDDEV_POP_IMPL
 provsql.rv_stddev_pop_impl(ind rv, x rv)
Oid OID_AGG_RV_STDDEV_SAMP_IMPL
 provsql.rv_stddev_samp_impl(ind rv, x rv)
Oid OID_AGG_RV_PERCENTILE_IMPL
 provsql.rv_percentile_impl(fraction float8, ind rv, x rv)
@c "X | (predicate)" placeholder OIDs (carrier-parametric).

Each is a no-op placeholder operator whose right operand is a Boolean combination of random_variable / agg_token comparisons; the planner converts that predicate into a condition gate and emits the matching conditioning constructor.

InvalidOid disables the rewrite.

Oid OID_FUNCTION_COND_PREDICATE
 cond_predicate(uuid,boolean)
Oid OID_FUNCTION_RV_COND_PREDICATE
 random_variable_cond_predicate(random_variable,boolean)
Oid OID_FUNCTION_AGG_COND_PREDICATE
 agg_token_cond_predicate(agg_token,boolean)
Oid OID_FUNCTION_PREDICATE_COND_PREDICATE
 predicate_cond_predicate(boolean,boolean) – (A)|(B), both events
Oid OID_FUNCTION_GIVEN_PREDICATE
 given_predicate(boolean) – prefix whole-tuple

Detailed Description

Structure to store the value of various constants.

This is needed to uniquely identify types, functions, etc., in PostgreSQL through their Object Identifier Types (OIDs).

Definition at line 189 of file provsql_utils.h.

Member Data Documentation

◆ GATE_TYPE_TO_OID

Oid constants_t::GATE_TYPE_TO_OID[nb_gate_types]

Array of the OID of each provenance_gate ENUM value.

Definition at line 211 of file provsql_utils.h.

◆ OID_AGG_AVG_RV

Oid constants_t::OID_AGG_AVG_RV

provsql.avg(random_variable)

Definition at line 244 of file provsql_utils.h.

◆ OID_AGG_CORR_RV

Oid constants_t::OID_AGG_CORR_RV

provsql.corr(rv, rv)

Definition at line 261 of file provsql_utils.h.

◆ OID_AGG_COVAR_POP_RV

Oid constants_t::OID_AGG_COVAR_POP_RV

SQL-standard statistic aggregates over random_variable rows and their internal indicator-carrying rewrite targets.

The public forms wrap every row with the certain indicator as_random(1); a provenance-tracked query is rewritten by make_rv_aggregate_expression to the _impl form whose extra leading argument is the row's provenance indicator rv_aggregate_indicator(prov), so absent rows drop out of the statistic (count, sums, and the percentile's member set alike). provsql.covar_pop(rv, rv)

Definition at line 259 of file provsql_utils.h.

◆ OID_AGG_COVAR_SAMP_RV

Oid constants_t::OID_AGG_COVAR_SAMP_RV

provsql.covar_samp(rv, rv)

Definition at line 260 of file provsql_utils.h.

◆ OID_AGG_MAX_RV

Oid constants_t::OID_AGG_MAX_RV

provsql.max(random_variable)

Definition at line 245 of file provsql_utils.h.

◆ OID_AGG_MIN_RV

Oid constants_t::OID_AGG_MIN_RV

provsql.min(random_variable)

Definition at line 246 of file provsql_utils.h.

◆ OID_AGG_PERCENTILE_CONT_RV

Oid constants_t::OID_AGG_PERCENTILE_CONT_RV

provsql.percentile_cont(float8) WITHIN GROUP (ORDER BY rv)

Definition at line 264 of file provsql_utils.h.

◆ OID_AGG_PRODUCT_RV

Oid constants_t::OID_AGG_PRODUCT_RV

provsql.product(random_variable)

Definition at line 243 of file provsql_utils.h.

◆ OID_AGG_RV_CORR_IMPL

Oid constants_t::OID_AGG_RV_CORR_IMPL

provsql.rv_corr_impl(ind rv, x rv, y rv)

Definition at line 267 of file provsql_utils.h.

◆ OID_AGG_RV_COVAR_POP_IMPL

Oid constants_t::OID_AGG_RV_COVAR_POP_IMPL

provsql.rv_covar_pop_impl(ind rv, x rv, y rv)

Definition at line 265 of file provsql_utils.h.

◆ OID_AGG_RV_COVAR_SAMP_IMPL

Oid constants_t::OID_AGG_RV_COVAR_SAMP_IMPL

provsql.rv_covar_samp_impl(ind rv, x rv, y rv)

Definition at line 266 of file provsql_utils.h.

◆ OID_AGG_RV_PERCENTILE_IMPL

Oid constants_t::OID_AGG_RV_PERCENTILE_IMPL

provsql.rv_percentile_impl(fraction float8, ind rv, x rv)

Definition at line 270 of file provsql_utils.h.

◆ OID_AGG_RV_STDDEV_POP_IMPL

Oid constants_t::OID_AGG_RV_STDDEV_POP_IMPL

provsql.rv_stddev_pop_impl(ind rv, x rv)

Definition at line 268 of file provsql_utils.h.

◆ OID_AGG_RV_STDDEV_SAMP_IMPL

Oid constants_t::OID_AGG_RV_STDDEV_SAMP_IMPL

provsql.rv_stddev_samp_impl(ind rv, x rv)

Definition at line 269 of file provsql_utils.h.

◆ OID_AGG_RV_SUM_OR_NULL

Oid constants_t::OID_AGG_RV_SUM_OR_NULL

provsql.rv_sum_or_null(random_variable): the avg-numerator sum, NULL on an empty group (so avg is NULL for an empty group after STRICT division)

Definition at line 247 of file provsql_utils.h.

◆ OID_AGG_STDDEV_POP_RV

Oid constants_t::OID_AGG_STDDEV_POP_RV

provsql.stddev_pop(rv)

Definition at line 262 of file provsql_utils.h.

◆ OID_AGG_STDDEV_SAMP_RV

Oid constants_t::OID_AGG_STDDEV_SAMP_RV

provsql.stddev_samp(rv)

Definition at line 263 of file provsql_utils.h.

◆ OID_AGG_SUM_RV

Oid constants_t::OID_AGG_SUM_RV

OIDs of the RV-returning aggregates, keyed for the per-aggregate identity dispatch in make_rv_aggregate_expression (product / max / min bake their identity into the wrap; avg rewrites to sum/sum).

provsql.sum(random_variable)

Definition at line 242 of file provsql_utils.h.

◆ OID_FUNCTION_AGG_CASE

Oid constants_t::OID_FUNCTION_AGG_CASE

OID of agg_case(uuid[]), the agg_token constructor the planner hook lowers an aggregate-carrier CASE into.

InvalidOid on a schema predating it (the rewrite is then disabled).

Definition at line 366 of file provsql_utils.h.

◆ OID_FUNCTION_AGG_COND

Oid constants_t::OID_FUNCTION_AGG_COND

OID of provsql.agg_token_cond(agg_token,uuid): the conditioning constructor for the agg_token carrier the planner emits when rewriting the "SUM(x) | (predicate)" placeholder.

Definition at line 326 of file provsql_utils.h.

◆ OID_FUNCTION_AGG_COND_PREDICATE

Oid constants_t::OID_FUNCTION_AGG_COND_PREDICATE

agg_token_cond_predicate(agg_token,boolean)

Definition at line 335 of file provsql_utils.h.

◆ OID_FUNCTION_AGG_TOKEN_UUID

Oid constants_t::OID_FUNCTION_AGG_TOKEN_UUID

OID of the agg_token_uuid FUNCTION.

Definition at line 220 of file provsql_utils.h.

◆ OID_FUNCTION_AGG_VALUE_GATE

Oid constants_t::OID_FUNCTION_AGG_VALUE_GATE

agg_value_gate(numeric) -> uuid

Definition at line 221 of file provsql_utils.h.

◆ OID_FUNCTION_ANNOTATE

Oid constants_t::OID_FUNCTION_ANNOTATE

OID of provsql.annotate(uuid,text)->uuid.

Wraps its child in a fresh transparent gate_annotation whose UUID folds in the extra text, and returns the wrapper's UUID. Used to attach the inversion-free tractability certificate (on the root) and the per-input order keys. InvalidOid on a schema predating the gate (the inversion-free carrier is then disabled).

Definition at line 290 of file provsql_utils.h.

◆ OID_FUNCTION_ARRAY_AGG

Oid constants_t::OID_FUNCTION_ARRAY_AGG

OID of the array_agg FUNCTION.

Definition at line 203 of file provsql_utils.h.

◆ OID_FUNCTION_ASSUME_BOOLEAN

Oid constants_t::OID_FUNCTION_ASSUME_BOOLEAN

OID of provsql.assume_boolean(uuid)->uuid.

Installed by the 1.5.0--1.6.0 upgrade script. Wraps its child in a fresh gate_assumed and returns the wrapper's UUID. When InvalidOid the safe-query rewriter (and any other Boolean-only rewrite that needs the marker) is effectively disabled even if provsql.boolean_provenance is on: the rewriter refuses to produce unmarked roots on a schema that cannot enforce the semiring-compatibility check.

Definition at line 282 of file provsql_utils.h.

◆ OID_FUNCTION_CHOOSE

Oid constants_t::OID_FUNCTION_CHOOSE

OID of the choose(anyelement) aggregate (keeps the first non-NULL value); used to decorrelate scalar subqueries into a LEFT JOIN + GROUP BY.

Definition at line 272 of file provsql_utils.h.

◆ OID_FUNCTION_COND

Oid constants_t::OID_FUNCTION_COND

OID of provsql.cond(uuid,uuid)->uuid.

Builds the terminal gate_conditioned (value-level conditioning, the binary | operator). The rewriter wraps a row's output provenance in it when a given(...) marker is present. InvalidOid on a schema predating the conditioning feature (the given rewrite is then disabled).

Definition at line 311 of file provsql_utils.h.

◆ OID_FUNCTION_COND_PREDICATE

Oid constants_t::OID_FUNCTION_COND_PREDICATE

cond_predicate(uuid,boolean)

Definition at line 333 of file provsql_utils.h.

◆ OID_FUNCTION_GATE_ONE

Oid constants_t::OID_FUNCTION_GATE_ONE

OID of the provenance_one FUNCTION.

Definition at line 217 of file provsql_utils.h.

◆ OID_FUNCTION_GATE_ZERO

Oid constants_t::OID_FUNCTION_GATE_ZERO

OID of the provenance_zero FUNCTION.

Definition at line 216 of file provsql_utils.h.

◆ OID_FUNCTION_GET_CHILDREN

Oid constants_t::OID_FUNCTION_GET_CHILDREN

OID of the get_children FUNCTION.

Definition at line 222 of file provsql_utils.h.

◆ OID_FUNCTION_GET_EXTRA

Oid constants_t::OID_FUNCTION_GET_EXTRA

OID of the get_extra FUNCTION.

Definition at line 223 of file provsql_utils.h.

◆ OID_FUNCTION_GIVEN

Oid constants_t::OID_FUNCTION_GIVEN

OID of provsql.given(uuid)->uuid.

The whole-tuple output-conditioning marker: a consumed select-list term the rewriter strips from the visible projection, conditioning each output row's provenance on the marker's argument. InvalidOid on a schema predating the feature.

Definition at line 318 of file provsql_utils.h.

◆ OID_FUNCTION_GIVEN_PREDICATE

Oid constants_t::OID_FUNCTION_GIVEN_PREDICATE

given_predicate(boolean) – prefix whole-tuple

Definition at line 337 of file provsql_utils.h.

◆ OID_FUNCTION_INVERSION_FREE_KEY

Oid constants_t::OID_FUNCTION_INVERSION_FREE_KEY

OID of provsql.inversion_free_key(text,text,int)->text.

Builds the K-prefixed per-input order-key string the planner attaches (via annotate) to each certified atom's provenance on the inversion-free path. InvalidOid on a schema predating it (markers are then not attached; the path declines and falls back).

Definition at line 297 of file provsql_utils.h.

◆ OID_FUNCTION_NOT_EQUAL_UUID

Oid constants_t::OID_FUNCTION_NOT_EQUAL_UUID

OID of the = operator on UUIDs FUNCTION.

Definition at line 219 of file provsql_utils.h.

◆ OID_FUNCTION_PREDICATE_COND_PREDICATE

Oid constants_t::OID_FUNCTION_PREDICATE_COND_PREDICATE

predicate_cond_predicate(boolean,boolean) – (A)|(B), both events

Definition at line 336 of file provsql_utils.h.

◆ OID_FUNCTION_PROBABILITY_EVALUATE

Oid constants_t::OID_FUNCTION_PROBABILITY_EVALUATE

OID of the real provsql.probability_evaluate(uuid,text,text).

The target of the probability(<predicate>) rewrite: the planner emits a call to it over the event token built from the Boolean argument.

Definition at line 347 of file provsql_utils.h.

◆ OID_FUNCTION_PROBABILITY_PREDICATE

Oid constants_t::OID_FUNCTION_PROBABILITY_PREDICATE

OID of the probability(boolean,text,text) placeholder.

When its argument carries a probabilistic (random_variable / aggregate) comparison the planner rewrites the whole call into probability_evaluate over the argument's event token; a purely deterministic argument is left to the SQL body (which returns 1/0). The predicate surface is only on probability, not probability_evaluate, to avoid an unknown-literal overload ambiguity (see sql/provsql.common.sql). InvalidOid disables the rewrite.

Definition at line 356 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE

Oid constants_t::OID_FUNCTION_PROVENANCE

OID of the provenance FUNCTION.

Definition at line 210 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE_AGGREGATE

Oid constants_t::OID_FUNCTION_PROVENANCE_AGGREGATE

OID of the provenance_aggregate FUNCTION.

Definition at line 214 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE_CMP

Oid constants_t::OID_FUNCTION_PROVENANCE_CMP

OID of the provenance_cmp FUNCTION.

Definition at line 209 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE_CMP_TIMES

Oid constants_t::OID_FUNCTION_PROVENANCE_CMP_TIMES

OID of the provenance_cmp_times FUNCTION.

Definition at line 213 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE_DELTA

Oid constants_t::OID_FUNCTION_PROVENANCE_DELTA

OID of the provenance_delta FUNCTION.

Definition at line 212 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE_EQ

Oid constants_t::OID_FUNCTION_PROVENANCE_EQ

OID of the provenance_eq FUNCTION.

Definition at line 208 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE_MONUS

Oid constants_t::OID_FUNCTION_PROVENANCE_MONUS

OID of the provenance_monus FUNCTION.

Definition at line 206 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE_PLUS

Oid constants_t::OID_FUNCTION_PROVENANCE_PLUS

OID of the provenance_plus FUNCTION.

Definition at line 204 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE_PROJECT

Oid constants_t::OID_FUNCTION_PROVENANCE_PROJECT

OID of the provenance_project FUNCTION.

Definition at line 207 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE_SEMIMOD

Oid constants_t::OID_FUNCTION_PROVENANCE_SEMIMOD

OID of the provenance_semimod FUNCTION.

Definition at line 215 of file provsql_utils.h.

◆ OID_FUNCTION_PROVENANCE_TIMES

Oid constants_t::OID_FUNCTION_PROVENANCE_TIMES

OID of the provenance_times FUNCTION.

Definition at line 205 of file provsql_utils.h.

◆ OID_FUNCTION_REGULAR_INDICATOR

Oid constants_t::OID_FUNCTION_REGULAR_INDICATOR

OID of provsql.regular_indicator(boolean): the deterministic gate_one/gate_zero indicator the planner emits for an ordinary (regular-type) comparison appearing inside a mixed conditioning predicate.

Definition at line 343 of file provsql_utils.h.

◆ OID_FUNCTION_RV_AGGREGATE_INDICATOR

Oid constants_t::OID_FUNCTION_RV_AGGREGATE_INDICATOR

OID of rv_aggregate_indicator(uuid) -> rv: the avg denominator wrap mixture(prov, 1, 0).

Definition at line 235 of file provsql_utils.h.

◆ OID_FUNCTION_RV_AGGREGATE_INDICATOR_VALUED

Oid constants_t::OID_FUNCTION_RV_AGGREGATE_INDICATOR_VALUED

OID of rv_aggregate_indicator(uuid, rv) -> rv: NULL when the row's value is NULL (SQL NULL-skip for avg's count).

Definition at line 236 of file provsql_utils.h.

◆ OID_FUNCTION_RV_AGGREGATE_SEMIMOD

Oid constants_t::OID_FUNCTION_RV_AGGREGATE_SEMIMOD

OID of rv_aggregate_semimod(uuid, rv) -> rv: wraps a per-row argument as mixture(prov, rv, as_random(0)) (identity 0, for sum / avg-numerator).

Definition at line 233 of file provsql_utils.h.

◆ OID_FUNCTION_RV_AGGREGATE_SEMIMOD_ID

Oid constants_t::OID_FUNCTION_RV_AGGREGATE_SEMIMOD_ID

OID of the 3-arg rv_aggregate_semimod(uuid, rv, float8): identity-parameterised wrap mixture(prov, rv, as_random(identity)) for product / max / min.

Definition at line 234 of file provsql_utils.h.

◆ OID_FUNCTION_RV_CASE

Oid constants_t::OID_FUNCTION_RV_CASE

OID of provsql.rv_case(uuid[])->random_variable.

Builds a gate_case from the flattened [guard_1, value_1, ..., default] wire list the planner emits for an RV-typed CASE expression. InvalidOid on a schema predating gate_case (the CASE-over-RV rewrite is then disabled).

Definition at line 362 of file provsql_utils.h.

◆ OID_FUNCTION_RV_CMP

Oid constants_t::OID_FUNCTION_RV_CMP[6]

OIDs of the random_variable_{eq,ne,le,lt,ge,gt} comparison procedure functions, indexed by the ComparisonOperator enum (EQ=0, NE=1, LE=2, LT=3, GE=4, GT=5; matches the order in src/Aggregation.h).

Used by the planner hook to detect RV-comparison OpExpr nodes in WHERE clauses.

Definition at line 303 of file provsql_utils.h.

◆ OID_FUNCTION_RV_COND

Oid constants_t::OID_FUNCTION_RV_COND

OID of provsql.random_variable_cond(random_variable,uuid).

The real conditioning constructor the planner emits when rewriting the "X | (predicate)" placeholder. InvalidOid disables the rewrite.

Definition at line 322 of file provsql_utils.h.

◆ OID_FUNCTION_RV_COND_PREDICATE

Oid constants_t::OID_FUNCTION_RV_COND_PREDICATE

random_variable_cond_predicate(random_variable,boolean)

Definition at line 334 of file provsql_utils.h.

◆ OID_FUNCTION_RV_DIV

Oid constants_t::OID_FUNCTION_RV_DIV

OID of random_variable_div(rv, rv) -> rv: builds the avg num/denom division gate.

Definition at line 237 of file provsql_utils.h.

◆ OID_FUNCTION_RV_GREATEST

Oid constants_t::OID_FUNCTION_RV_GREATEST

provsql.greatest(VARIADIC random_variable[])

Definition at line 230 of file provsql_utils.h.

◆ OID_FUNCTION_RV_LEAST

Oid constants_t::OID_FUNCTION_RV_LEAST

provsql.least(VARIADIC random_variable[])

Definition at line 231 of file provsql_utils.h.

◆ OID_OPERATOR_NOT_EQUAL_UUID

Oid constants_t::OID_OPERATOR_NOT_EQUAL_UUID

OID of the <> operator on UUIDs FUNCTION.

Definition at line 218 of file provsql_utils.h.

◆ OID_SCHEMA_PROVSQL

Oid constants_t::OID_SCHEMA_PROVSQL

OID of the provsql SCHEMA.

Definition at line 190 of file provsql_utils.h.

◆ OID_TYPE_AGG_TOKEN

Oid constants_t::OID_TYPE_AGG_TOKEN

OID of the agg_token TYPE.

Definition at line 192 of file provsql_utils.h.

◆ OID_TYPE_BOOL

Oid constants_t::OID_TYPE_BOOL

OID of the BOOL TYPE.

Definition at line 195 of file provsql_utils.h.

◆ OID_TYPE_FLOAT

Oid constants_t::OID_TYPE_FLOAT

OID of the FLOAT TYPE.

Definition at line 198 of file provsql_utils.h.

◆ OID_TYPE_GATE_TYPE

Oid constants_t::OID_TYPE_GATE_TYPE

OID of the provenance_gate TYPE.

Definition at line 191 of file provsql_utils.h.

◆ OID_TYPE_INT

Oid constants_t::OID_TYPE_INT

OID of the INT TYPE.

Definition at line 196 of file provsql_utils.h.

◆ OID_TYPE_INT4MULTIRANGE

Oid constants_t::OID_TYPE_INT4MULTIRANGE

OID of the int4multirange TYPE (PG14+, InvalidOid otherwise).

Definition at line 202 of file provsql_utils.h.

◆ OID_TYPE_INT_ARRAY

Oid constants_t::OID_TYPE_INT_ARRAY

OID of the INT[] TYPE.

Definition at line 197 of file provsql_utils.h.

◆ OID_TYPE_NUMMULTIRANGE

Oid constants_t::OID_TYPE_NUMMULTIRANGE

OID of the nummultirange TYPE (PG14+, InvalidOid otherwise).

Definition at line 201 of file provsql_utils.h.

◆ OID_TYPE_RANDOM_VARIABLE

Oid constants_t::OID_TYPE_RANDOM_VARIABLE

OID of the random_variable TYPE.

Definition at line 225 of file provsql_utils.h.

◆ OID_TYPE_RANDOM_VARIABLE_ARRAY

Oid constants_t::OID_TYPE_RANDOM_VARIABLE_ARRAY

OID of the random_variable[] TYPE.

Definition at line 226 of file provsql_utils.h.

◆ OID_TYPE_TSTZMULTIRANGE

Oid constants_t::OID_TYPE_TSTZMULTIRANGE

OID of the tstzmultirange TYPE (PG14+, InvalidOid otherwise).

Definition at line 200 of file provsql_utils.h.

◆ OID_TYPE_UUID

Oid constants_t::OID_TYPE_UUID

OID of the uuid TYPE.

Definition at line 193 of file provsql_utils.h.

◆ OID_TYPE_UUID_ARRAY

Oid constants_t::OID_TYPE_UUID_ARRAY

OID of the uuid[] TYPE.

Definition at line 194 of file provsql_utils.h.

◆ OID_TYPE_VARCHAR

Oid constants_t::OID_TYPE_VARCHAR

OID of the VARCHAR TYPE.

Definition at line 199 of file provsql_utils.h.

◆ OID_UNNEST

Oid constants_t::OID_UNNEST

OID of the unnest(anyarray) FUNCTION.

Definition at line 224 of file provsql_utils.h.

◆ ok

bool constants_t::ok

true if constants were loaded

Definition at line 367 of file provsql_utils.h.


The documentation for this struct was generated from the following file: