Re: Bulk Data Entry

Поиск
Список
Период
Сортировка
От Richard Huxton
Тема Re: Bulk Data Entry
Дата
Msg-id 46010957.4080002@archonet.com
обсуждение исходный текст
Ответ на Bulk Data Entry  (Naz Gassiep <naz@mira.net>)
Ответы Re: Bulk Data Entry
Список pgsql-general
Naz Gassiep wrote:
> psql blogbogdev -f ./blogbog_tables.sql > ./blogbog_tables_inserted.log
> psql blogbogdev -f ./blogbog_data.sql > ./blogbog_data_inserted.log
> psql blogbogdev -f ./blogbog_constraints.sql >
> ./blogbog_constraints_applied.log

> I really would prefer psql to halt on error instead of just continuing
> to plow right ahead, but IIRC there was a discussion about this and it
> was decided that continuing was the best behavior.

Check the psql man-page for "ON_ERROR_STOP":
psql ... -v 'ON_ERROR_STOP=' ...

> I have grepped the .log files that the script outputs for "ERROR" but
> there is none. How would one go about finding where the error in an SQL
> script is?

You're not redirecting STDERR, just STDOUT

psql .... >insert.log 2>insert.err

--
   Richard Huxton
   Archonet Ltd

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

Предыдущее
От: Naz Gassiep
Дата:
Сообщение: Re: Lifecycle of PostgreSQL releases
Следующее
От: Richard Huxton
Дата:
Сообщение: Re: Bulk Data Entry