aboutsummaryrefslogtreecommitdiff
path: root/src/include/storage/itemptr.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/storage/itemptr.h')
-rw-r--r--src/include/storage/itemptr.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/include/storage/itemptr.h b/src/include/storage/itemptr.h
index 6c9ed3696b7..626c98f9691 100644
--- a/src/include/storage/itemptr.h
+++ b/src/include/storage/itemptr.h
@@ -154,6 +154,22 @@ typedef ItemPointerData *ItemPointer;
(pointer)->ip_posid = InvalidOffsetNumber \
)
+/*
+ * ItemPointerIndicatesMovedPartitions
+ * True iff the block number indicates the tuple has moved to another
+ * partition.
+ */
+#define ItemPointerIndicatesMovedPartitions(pointer) \
+ !BlockNumberIsValid(ItemPointerGetBlockNumberNoCheck(pointer))
+
+/*
+ * ItemPointerSetMovedPartitions
+ * Indicate that the item referenced by the itempointer has moved into a
+ * different partition.
+ */
+#define ItemPointerSetMovedPartitions(pointer) \
+ ItemPointerSetBlockNumber((pointer), InvalidBlockNumber)
+
/* ----------------
* externs
* ----------------