Expand description
Helper functions for creating Postgres UDFs
Typically these functions are not necessary to call directly as they’re used behind
the scenes by the code generated by the #[pg_extern]
macro.
Structs§
- The equivalent of a PostgreSQL
NULL
Functions§
- This mimics the functionality of Postgres’
DirectFunctionCall
macros, allowing you to call internal Postgres functions using its “V1” calling convention. Unlike the Postgres C macros, the function is allowed to return a NULL datum. - Same as direct_function_call but instead returns the direct
Option<pg_sys::Datum>
instead of converting it to a value - Akin to direct_function_call, but specifically for calling those functions declared with the
#[pg_extern]
attribute. - Same as direct_pg_extern_function_call but instead returns the direct
Option<pg_sys::Datum>
instead of converting it to a value - Is the specified argument for a
PG_FUNCTION_INFO_V1
function NULL? - Retrieve the
.flinfo.fn_extra
pointer (as a PgBox’d type) frompg_sys::FunctionCallInfo
. - Get the collation the function call should use
- Returns the
pg_sys::NullableDatum
for a given arg. - Get a numbered argument for a
PG_FUNCTION_INFO_V1
function as the specified Rust type. - Get a numbered argument for a
PG_FUNCTION_INFO_V1
function as an Option containing apg_sys::Datum
. - Get a numbered argument for a
PG_FUNCTION_INFO_V1
function as a rawpg_sys::Datum
. - Safety
- Modifies the specified
fcinfo
struct to indicate that its return value is null. - Indicates that a
PG_FUNCTION_INFO_V1
function is returning a SQL “void”. - srf_
first_ ⚠call_ init Deprecated - srf_
per_ ⚠call_ setup Deprecated