Re: Question about running "Vacuum" through JDBC

Поиск
Список
Период
Сортировка
От Brad Nicholson
Тема Re: Question about running "Vacuum" through JDBC
Дата
Msg-id 427B92A5.2010004@ca.afilias.info
обсуждение исходный текст
Ответ на Question about running "Vacuum" through JDBC  (Ying Lu <ying_lu@cs.concordia.ca>)
Список pgsql-general
Ying Lu wrote:

> Greetings,
>
> I tried to "Vacuum table" through JDBC. I got the following errors:
>
>   ERROR: VACUUM cannot run inside a transaction block
>
> Does it mean I should only run vacuum through the command line such as
> "psql>  vacuum TableName "?

Nope, it means exactly what the error says.  You are trying to run vacum
inside a transaction, which can't be done.  JDBC is likely opening a
transaction for you automatically.  Stop it from doing this, and you
should be able to vacuum.

--
Brad Nicholson  416-673-4106
Database Administrator, Afilias Canada Corp.


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

Предыдущее
От: Ying Lu
Дата:
Сообщение: Question about running "Vacuum" through JDBC
Следующее
От: Michael Glaesemann
Дата:
Сообщение: Duplicate key error when updating unique columns