summaryrefslogtreecommitdiff
path: root/src/include/access/htup.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/access/htup.h')
-rw-r--r--src/include/access/htup.h51
1 files changed, 22 insertions, 29 deletions
diff --git a/src/include/access/htup.h b/src/include/access/htup.h
index 0b6653f386..72fb5a8d31 100644
--- a/src/include/access/htup.h
+++ b/src/include/access/htup.h
@@ -6,7 +6,7 @@
*
* Copyright (c) 1994, Regents of the University of California
*
- * $Id: htup.h,v 1.6 1997/09/08 21:50:46 momjian Exp $
+ * $Id: htup.h,v 1.7 1997/11/02 15:26:42 vadim Exp $
*
*-------------------------------------------------------------------------
*/
@@ -28,33 +28,25 @@
*/
typedef struct HeapTupleData
{
+ unsigned int t_len; /* length of entire tuple */
- unsigned int t_len; /* length of entire tuple */
+ Oid t_oid; /* OID of this tuple -- 4 bytes */
- ItemPointerData t_ctid; /* current TID of this tuple */
+ CommandId t_cmin; /* insert CID stamp -- 4 bytes each */
+ CommandId t_cmax; /* delete CommandId stamp */
- ItemPointerData t_chain; /* replaced tuple TID */
+ TransactionId t_xmin; /* insert XID stamp -- 4 bytes each */
+ TransactionId t_xmax; /* delete XID stamp */
- Oid t_oid; /* OID of this tuple -- 4 bytes */
+ ItemPointerData t_ctid; /* current TID of this tuple */
+
+ int16 t_natts; /* number of attributes */
- CommandId t_cmin; /* insert CID stamp -- 2 bytes each */
- CommandId t_cmax; /* delete CommandId stamp */
+ uint16 t_infomask; /* various infos */
- TransactionId t_xmin; /* insert XID stamp -- 4 bytes each */
- TransactionId t_xmax; /* delete XID stamp */
+ uint8 t_hoff; /* sizeof tuple header */
- AbsoluteTime t_tmin; /* time stamps -- 4 bytes each */
- AbsoluteTime t_tmax;
-
- int16 t_natts; /* number of attributes */
- char t_vtype; /* not used - padding */
-
- char t_infomask; /* whether tuple as null or variable
- * length attributes */
-
- uint8 t_hoff; /* sizeof tuple header */
-
- bits8 t_bits[MinHeapTupleBitmapSize / 8];
+ bits8 t_bits[MinHeapTupleBitmapSize / 8];
/* bit map of domains */
/* MORE DATA FOLLOWS AT END OF STRUCT */
@@ -69,12 +61,7 @@ typedef HeapTupleData *HeapTuple;
#define MinCommandIdAttributeNumber (-4)
#define MaxTransactionIdAttributeNumber (-5)
#define MaxCommandIdAttributeNumber (-6)
-#define ChainItemPointerAttributeNumber (-7)
-#define AnchorItemPointerAttributeNumber (-8)
-#define MinAbsoluteTimeAttributeNumber (-9)
-#define MaxAbsoluteTimeAttributeNumber (-10)
-#define VersionTypeAttributeNumber (-11)
-#define FirstLowInvalidHeapAttributeNumber (-12)
+#define FirstLowInvalidHeapAttributeNumber (-7)
/* ----------------
@@ -101,9 +88,15 @@ typedef HeapTupleData *HeapTuple;
/*
* information stored in t_infomask:
*/
-#define HEAP_HASNULL 0x01 /* has null attribute(s) */
-#define HEAP_HASVARLENA 0x02 /* has variable length
+#define HEAP_HASNULL 0x0001 /* has null attribute(s) */
+#define HEAP_HASVARLENA 0x0002 /* has variable length
* attribute(s) */
+#define HEAP_XMIN_COMMITTED 0x0100 /* t_xmin committed */
+#define HEAP_XMIN_INVALID 0x0200 /* t_xmin invalid/aborted */
+#define HEAP_XMAX_COMMITTED 0x0400 /* t_xmax committed */
+#define HEAP_XMAX_INVALID 0x0800 /* t_xmax invalid/aborted */
+
+#define HEAP_XACT_MASK 0x0F00 /* */
#define HeapTupleNoNulls(tuple) \
(!(((HeapTuple) (tuple))->t_infomask & HEAP_HASNULL))