xid type? (was :)

From: Christophe Pettus <xof(at)thebuild(dot)com>
To: Fabrice Chapuis <fabrice636861(at)gmail(dot)com>
Cc: "pgsql-generallists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: xid type? (was :)
Date: 2023-05-15 15:47:44
Message-ID: F8488A2C-22D2-410E-A899-4F64887748E7@thebuild.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

> On May 15, 2023, at 08:41, Fabrice Chapuis <fabrice636861(at)gmail(dot)com> wrote:
> What is the xid type and how can I cast integer value to make pg_xact_commit_timestamp to work?

The xid type is... xid. You'll need to cast as a string instead of an integer:

xof=# select pg_xact_commit_timestamp('53013547'::xid);
pg_xact_commit_timestamp
-------------------------------
2023-03-31 09:12:07.673883-07
(1 row)

In response to

  • at 2023-05-15 15:41:47 from Fabrice Chapuis

Browse pgsql-general by date

  From Date Subject
Next Message Kirk Wolak 2023-05-16 01:26:16 Re: Adding SHOW CREATE TABLE
Previous Message Fabrice Chapuis 2023-05-15 15:41:47