Re: Transaction IDs not the same in same transaction? - Mailing list pgsql-general

From Steve V
Subject Re: Transaction IDs not the same in same transaction?
Date
Msg-id 58cabeec0510232152t3959af94s193214b9e1cccf92@mail.gmail.com
Whole thread Raw
In response to Re: Transaction IDs not the same in same transaction?  (Neil Conway <neilc@samurai.com>)
List pgsql-general
> It's defined in the backend executable, as is GetCurrentTransactionId().
> A similar wrapper function to the one shown here:
>
> http://archives.postgresql.org/pgsql-general/2005-06/msg00709.php
>
> should work. But I agree with the other folks in this thread who have
> questioned whether this is a good idea: backend APIs are known to change
> significantly between releases, and making assumptions about how they
> behave seems like asking for trouble to me.

I agree with all of you as well that using backend APIs is not the
most continually reliable way of doing this. Unfortunately the
requirement stands that I need to audit all actions that occur in a
single transaction, as one group.

Christian's method seems like it should work properly. Does anyone see
any problems with doing it in the fashion mentioned by him?

pgsql-general by date:

Previous
From: Steve V
Date:
Subject: Re: Transaction IDs not the same in same transaction?
Next
From: Romain Vinot
Date:
Subject: Migration from 8.0 to 7.4...