Functions§
- Heap
Tuple ⚠GetRaw Command Id - 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!
- Heap
Tuple ⚠Header Frozen - Does the specified
HeapTupleHeaderData
represent a “frozen” tuple? - Heap
Tuple ⚠Header GetNatts - How many attributes does the specified
HeapTupleHeader
have? - Heap
Tuple ⚠Header GetRaw Xmin - 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.
- Heap
Tuple ⚠Header GetXmin - Returns the
xmin
value of the specifiedHeapTupleHeaderData
- Heap
Tuple ⚠Header IsHeap Only - Safety
- Heap
Tuple ⚠Header IsHot Updated - Safety
- Heap
Tuple ⚠Header Xmin Invalid - Safety
- Heap
Tuple ⚠NoNulls - 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.