Module submodules

Module submodules 

Source

Modules§

cmp
datum
elog
Access to Postgres’ logging system
errcodes
ffi
htup
oids
panic
pg_try
transaction_id
tupdesc
Provides helper implementations for various TupleDesc-related structs
utils
General utility functions

Structs§

Datum
Datum is an abstract value that is effectively a union of all scalar types and all possible pointers in a Postgres context. That is, it is either “pass-by-value” (if the value fits into the platform’s uintptr_t) or “pass-by-reference” (if it does not).
Oid
An object identifier in Postgres.
PgTryBuilder
PgTryBuilder is a mechanism to mimic Postgres C macros PG_TRY and PG_CATCH.
TransactionId
An xid type from PostgreSQL

Enums§

NotBuiltinOid
PgOid

Functions§

HeapTupleGetRawCommandId
HeapTupleHeaderGetRawCommandId will give you what’s in the header whether it is useful or not. Most code should use HeapTupleHeaderGetCmin or HeapTupleHeaderGetCmax instead, but note that those Assert that you can get a legitimate result, ie you are in the originating transaction!
HeapTupleHeaderFrozen
Does the specified HeapTupleHeaderData represent a “frozen” tuple?
HeapTupleHeaderGetNatts
How many attributes does the specified HeapTupleHeader have?
HeapTupleHeaderGetRawXmin
HeapTupleHeaderGetRawXmin returns the “raw” xmin field, which is the xid originally used to insert the tuple. However, the tuple might actually be frozen (via HeapTupleHeaderSetXminFrozen) in which case the tuple’s xmin is visible to every snapshot. Prior to PostgreSQL 9.4, we actually changed the xmin to FrozenTransactionId, and that value may still be encountered on disk.
HeapTupleHeaderGetXmin
Returns the xmin value of the specified HeapTupleHeaderData
HeapTupleHeaderIsHeapOnly
Safety
HeapTupleHeaderIsHotUpdated
Safety
HeapTupleHeaderXminInvalid
Safety
HeapTupleNoNulls
Does the specified HeapTuple contain nulls?
heap_getattr
Extract an attribute of a heap tuple and return it as a Datum. This works for either system or user attributes. The given attnum is properly range-checked.
name_data_to_str
Converts a pg_sys::NameData struct into a &str.

Type Aliases§

MultiXactId
PgBuiltInOids