Re: Optimising inside transactions

Поиск
Список
Период
Сортировка
От Manfred Koizar
Тема Re: Optimising inside transactions
Дата
Msg-id fl3fgu0b76dq1lje2knpvi155vgmmteef7@4ax.com
обсуждение исходный текст
Ответ на Optimising inside transactions  (John Taylor <postgres@jtresponse.co.uk>)
Список pgsql-novice
On Wed, 12 Jun 2002 16:07:26 +0100, John Taylor
<postgres@jtresponse.co.uk> wrote:
>
>Hi,
>
>I'm running a transaction with about 1600 INSERTs.
>Each INSERT involves a subselect.
>
>I've noticed that if one of the INSERTs fails, the remaining INSERTs run in about
>1/2 the time expected.
>
>Is postgresql optimising the inserts, knowing that it will rollback at the end ?
>
ISTM "optimising" is not the right word, it doesn't even try to
execute them.

fred=# BEGIN;
BEGIN
fred=# INSERT INTO a VALUES (1, 'x');
INSERT 174658 1
fred=# blabla;
ERROR:  parser: parse error at or near "blabla"
fred=# INSERT INTO a VALUES (2, 'y');
NOTICE:  current transaction is aborted, queries ignored until end of
transaction block
*ABORT STATE*
fred=# ROLLBACK;
ROLLBACK

Servus
 Manfred

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

Предыдущее
От: John Taylor
Дата:
Сообщение: Re: Optimising inside transactions
Следующее
От: Andrew McMillan
Дата:
Сообщение: Re: How efficient are Views