summaryrefslogtreecommitdiff
path: root/src/include/access/xact.h
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2005-06-29 22:51:57 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2005-06-29 22:51:57 +0000
commitb5f7cff84f57a189ed5c9dd59efe8d2568649d0d (patch)
tree77b5a25a7c4a62145ba89a578018121b3246b82d /src/include/access/xact.h
parentc33d575899593a46a5b9a76e4e0ef6f9d81e55dd (diff)
downloadpostgresql-b5f7cff84f57a189ed5c9dd59efe8d2568649d0d.tar.gz
Clean up the rather historically encumbered interface to now() and
current time: provide a GetCurrentTimestamp() function that returns current time in the form of a TimestampTz, instead of separate time_t and microseconds fields. This is what all the callers really want anyway, and it eliminates low-level dependencies on AbsoluteTime, which is a deprecated datatype that will have to disappear eventually.
Diffstat (limited to 'src/include/access/xact.h')
-rw-r--r--src/include/access/xact.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/include/access/xact.h b/src/include/access/xact.h
index 0c6b558068..ae5722ecb4 100644
--- a/src/include/access/xact.h
+++ b/src/include/access/xact.h
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/access/xact.h,v 1.77 2005/06/17 22:32:48 tgl Exp $
+ * $PostgreSQL: pgsql/src/include/access/xact.h,v 1.78 2005/06/29 22:51:57 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -17,7 +17,7 @@
#include "access/xlog.h"
#include "storage/relfilenode.h"
#include "nodes/pg_list.h"
-#include "utils/nabstime.h"
+#include "utils/timestamp.h"
/*
@@ -140,8 +140,7 @@ extern TransactionId GetCurrentTransactionId(void);
extern TransactionId GetCurrentTransactionIdIfAny(void);
extern SubTransactionId GetCurrentSubTransactionId(void);
extern CommandId GetCurrentCommandId(void);
-extern AbsoluteTime GetCurrentTransactionStartTime(void);
-extern AbsoluteTime GetCurrentTransactionStartTimeUsec(int *usec);
+extern TimestampTz GetCurrentTransactionStartTimestamp(void);
extern int GetCurrentTransactionNestLevel(void);
extern bool TransactionIdIsCurrentTransactionId(TransactionId xid);
extern void CommandCounterIncrement(void);