Re: Transactions and libpq

Поиск
Список
Период
Сортировка
От Michael Fuhr
Тема Re: Transactions and libpq
Дата
Msg-id 20060821232814.GA39874@winnie.fuhr.org
обсуждение исходный текст
Ответ на Transactions and libpq  (osxdeveloper@mac.com)
Список pgsql-interfaces
On Tue, Aug 22, 2006 at 01:11:33AM +0200, osxdeveloper@mac.com wrote:
> I am writing an application using the libqpsql client lib.

Do you mean libpq?  Are you coding in C?

> What I like to do now, is to control transaction behavior
> from within my application.
> But the following happens:
> When I try to open a transaction libpg prints
> "WARNING:  there is already a transaction in progress"
> to stdout.
> The question for me is - why??

As the error says: a transaction had already been started when the
application tried to start another one.  Can you post a simple but
complete program that demonstrates this behavior when you think it
shouldn't?  You could also enable statement logging on the server
to see everything the application is executing.

> I searched Google and found some confusing things about serverside
> auto-commit - but this is removed at last in Postgres 8.0.

Server-side autocommit existed only in 7.3.  What version of libpq
are you using, and what version of the server?

-- 
Michael Fuhr


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

Предыдущее
От: osxdeveloper@mac.com
Дата:
Сообщение: Transactions and libpq
Следующее
От: Ralf Hasemann
Дата:
Сообщение: libpgsql and transaction behaviour