Re: In-doubt window
| От | Tom Lane |
|---|---|
| Тема | Re: In-doubt window |
| Дата | |
| Msg-id | 5706.1066671313@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: In-doubt window ("Jeroen T. Vermeulen" <jtv@xs4all.nl>) |
| Ответы |
Re: In-doubt window
|
| Список | pgsql-hackers |
"Jeroen T. Vermeulen" <jtv@xs4all.nl> writes:
> On Mon, Oct 20, 2003 at 12:18:44PM -0400, Tom Lane wrote:
>> Another way you can look to see if a transaction has completed is to see
>> if there is still an ExclusiveLock record for it in pg_locks. For this
>> you need to know the transaction's internal XID, but you can get that
>> from the XMAX of the log record it deleted. In other words:
> Does this mean there's already a record in the database that (exists &&
> is locked) if and only if the transaction is still in progress?
It's not actually a record in the database ... pg_locks is a view of
internal lock-manager state. (It's new as of 7.3, BTW; dunno how far
back you want your stuff to work.) But it will get the job done for
you.
regards, tom lane
В списке pgsql-hackers по дате отправления: