File tree Expand file tree Collapse file tree 3 files changed +3
-4
lines changed Expand file tree Collapse file tree 3 files changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -396,7 +396,7 @@ error_commit_ts_disabled(void)
396
396
Datum
397
397
pg_xact_commit_timestamp (PG_FUNCTION_ARGS )
398
398
{
399
- TransactionId xid = PG_GETARG_UINT32 (0 );
399
+ TransactionId xid = PG_GETARG_TRANSACTIONID (0 );
400
400
TimestampTz ts ;
401
401
bool found ;
402
402
Original file line number Diff line number Diff line change 22
22
#include "libpq/pqformat.h"
23
23
#include "utils/builtins.h"
24
24
25
- #define PG_GETARG_TRANSACTIONID (n ) DatumGetTransactionId(PG_GETARG_DATUM(n))
26
- #define PG_RETURN_TRANSACTIONID (x ) return TransactionIdGetDatum(x)
27
-
28
25
#define PG_GETARG_COMMANDID (n ) DatumGetCommandId(PG_GETARG_DATUM(n))
29
26
#define PG_RETURN_COMMANDID (x ) return CommandIdGetDatum(x)
30
27
Original file line number Diff line number Diff line change @@ -236,6 +236,7 @@ extern struct varlena *pg_detoast_datum_packed(struct varlena * datum);
236
236
#define PG_GETARG_FLOAT4 (n ) DatumGetFloat4(PG_GETARG_DATUM(n))
237
237
#define PG_GETARG_FLOAT8 (n ) DatumGetFloat8(PG_GETARG_DATUM(n))
238
238
#define PG_GETARG_INT64 (n ) DatumGetInt64(PG_GETARG_DATUM(n))
239
+ #define PG_GETARG_TRANSACTIONID (n ) DatumGetTransactionId(PG_GETARG_DATUM(n))
239
240
/* use this if you want the raw, possibly-toasted input datum: */
240
241
#define PG_GETARG_RAW_VARLENA_P (n ) ((struct varlena *) PG_GETARG_POINTER(n))
241
242
/* use this if you want the input datum de-toasted: */
@@ -309,6 +310,7 @@ extern struct varlena *pg_detoast_datum_packed(struct varlena * datum);
309
310
#define PG_RETURN_FLOAT4 (x ) return Float4GetDatum(x)
310
311
#define PG_RETURN_FLOAT8 (x ) return Float8GetDatum(x)
311
312
#define PG_RETURN_INT64 (x ) return Int64GetDatum(x)
313
+ #define PG_RETURN_TRANSACTIONID (x ) return TransactionIdGetDatum(x)
312
314
/* RETURN macros for other pass-by-ref types will typically look like this: */
313
315
#define PG_RETURN_BYTEA_P (x ) PG_RETURN_POINTER(x)
314
316
#define PG_RETURN_TEXT_P (x ) PG_RETURN_POINTER(x)
You can’t perform that action at this time.
0 commit comments