how to ensure a client waits for a previous transaction to finish?

Поиск
Список
Период
Сортировка
От Dan Kortschak
Тема how to ensure a client waits for a previous transaction to finish?
Дата
Msg-id 1260219607.10944.8.camel@epistle
обсуждение исходный текст
Ответы Re: how to ensure a client waits for a previous transaction to finish?  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: how to ensure a client waits for a previous transaction to finish?  (John R Pierce <pierce@hogranch.com>)
Re: how to ensure a client waits for a previous transaction to finish?  (Vick Khera <vivek@khera.org>)
Список pgsql-general
Hi, this is a bit of a noob question.

I am using PGSql to perform some large analyses, with the clients being
a sequentially run set of perl scripts (one to set up and populate
tables and then down stream scripts to query the database for the
results).

During manual testing everything works, but automating it results in the
query scripts starting before the population transactions having
completed, so they give erroneous result.

How can I ensure the query scripts wait until the population transaction
processes have finished? I've looked at 'SET TRANSACTION ISOLATION LEVEL
SERIALIZABLE' (to us in the query scripts I thought), but I'm not sure
that is what I want.

Can any one suggest where I should be looking, or if SET TRANSACTION is
the right way to go?

thanks


В списке pgsql-general по дате отправления:

Предыдущее
От: Alan Hodgson
Дата:
Сообщение: Re: Add pg server to cluster
Следующее
От: Tom Lane
Дата:
Сообщение: Re: how to ensure a client waits for a previous transaction to finish?