Module htup

Source
Expand description

Utility functions for working with pg_sys::HeapTuple and pg_sys::HeapTupleHeader structs

Structs§

DatumWithTypeInfo

Traits§

IntoHeapTuple
Implemented for Rust tuples that can be represented as a Postgres pg_sys::HeapTupleData.

Functions§

composite_row_type_make_tuple
Given a pg_sys::Datum representing a composite row type, return a boxed HeapTupleData, which can be used by the various heap_getattr methods
heap_getattr
Extract an attribute of a heap tuple and return it as Rust type. This works for either system or user attributes. The given attnum is properly range-checked.
heap_getattr_datum_ex
Similar to heap_getattr(), but returns extended information about the requested attribute attno is 1-based
heap_getattr_raw
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.
heap_tuple_get_datum
convert a HeapTupleHeader to a Datum.
heap_tuple_header_get_datum_length
Safety
heap_tuple_header_get_type_id
heap_tuple_header_get_typmod