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 58cabeec0510231635l5c93bc91t205f8e7065f8b43e@mail.gmail.com
Whole thread Raw
In response to Re: Transaction IDs not the same in same transaction?  (Michael Fuhr <mike@fuhr.org>)
Responses Re: Transaction IDs not the same in same transaction?  (Neil Conway <neilc@samurai.com>)
Re: Transaction IDs not the same in same transaction?  (Michael Fuhr <mike@fuhr.org>)
List pgsql-general
> I just did some tests with a pltcl function that uses spi_exec in
> an AFTER trigger and GetTopTransactionId() returned the same value
> for each of several inserts and updates that were in the same
> transaction.  However, I can't say whether this will work for you
> without seeing your code.  It would be easier for us to help -- and
> you'd get a solution sooner -- if you'd post a minimal but complete
> example that shows what you're doing and that exhibits the behavior
> you're seeing.

Okay, so using GetTopTransactionId() will do the trick it sounds like.
To see all of what's happening, just place the pltcl function that I
posted earlier in this thread as an AFTER trigger, and run code
similar to that which I showed in my first post to start the thread.

Which library is GetTopTransactionId() available in? Do I need to
compile an library on my own that will expose it?

pgsql-general by date:

Previous
From: Michael Fuhr
Date:
Subject: Re: Transaction IDs not the same in same transaction?
Next
From: Allen
Date:
Subject: Re: out of memory for query result