Re: How to find transaction ID - Mailing list pgsql-general

From Glyn Astill
Subject Re: How to find transaction ID
Date
Msg-id 1375972598.43915.YahooMailNeo@web133205.mail.ir2.yahoo.com
Whole thread Raw
In response to Re: How to find transaction ID  (Glyn Astill <glynastill@yahoo.co.uk>)
List pgsql-general

> From: Glyn Astill <glynastill@yahoo.co.uk>
> To: "ascot.moss@gmail.com" <ascot.moss@gmail.com>; PostgreSQL general <pgsql-general@postgresql.org>
> Cc:
> Sent: Thursday, 8 August 2013, 15:20
> Subject: Re: [GENERAL] How to find transaction ID
>
>
>
>>  From: "ascot.moss@gmail.com" <ascot.moss@gmail.com>
>>  To: PostgreSQL general <pgsql-general@postgresql.org>
>>  Cc: ascot.moss@gmail.com
>>  Sent: Thursday, 8 August 2013, 14:52
>>  Subject: [GENERAL] How to find transaction ID
>>
>>  Hi,
>>
>>  I am trying some restore tools,  can you advise how to find the latest
>>  transaction ID in PostgreSQL and the transaction ID at a particular
>>  "Point-In-Time"?
>>
>
> Hmm, it's not clear entirely what you want.  Afaik "select
> txid_current()" should get you the current transaction id. The column xmin
> for a row from any table will get you the inserting transaction id, and xmax
> will get you the deleting (or attempted delete) transaction id.
>
> See http://www.postgresql.org/docs/9.0/static/functions-info.html
>

I guess I shouldn't have said that about xmin and xmax; you can't rely on those columns in various circumstances i.e.
aftera vacuum. 



pgsql-general by date:

Previous
From: dafNi zaf
Date:
Subject: DB transactions when browser freezes
Next
From: Adrian Klaver
Date:
Subject: Re: DB transactions when browser freezes