Re: initdb failure (was Re: [GENERAL] sequence's plpgsql)

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: initdb failure (was Re: [GENERAL] sequence's plpgsql)
Дата
Msg-id 200309271634.h8RGYs310644@candle.pha.pa.us
обсуждение исходный текст
Ответ на Re: initdb failure (was Re: [GENERAL] sequence's plpgsql)  (Peter Eisentraut <peter_e@gmx.net>)
Ответы Re: initdb failure (was Re: [GENERAL] sequence's plpgsql)  (Peter Eisentraut <peter_e@gmx.net>)
Список pgsql-hackers
Peter Eisentraut wrote:
> Oliver Elphick writes:
> 
> > +    <para>
> > +     With a large dump, it may be difficult to identify where any errors are
> > +     occurring.  You may use the -e option to psql to print the SQL commands
> > +     as they are run, so that it is easy to see precisely which commands are
> > +     causing errors.
> >      </para>
> 
> That is just not true.  If you use -f, it will tell you the line number of
> the command causing the error.  Add the line number of the COPY error
> message, there you have it.

You are assuming it is easy to find what is on a specific line of the
dump file.  I am not sure that is always easy for people with limited
Unix skills, or MSWin folks.  I am not sure I would have thought to add
the file offset to find the problem COPY line.  I guess I would have
eventually, but it wouldn't have been my first idea, and I might _not_
have used -f on the load, and if the load took an hour, I would have to
run it again to get that line number.

I can see the point that the table name is only really valuable when you
are loading a dump, and not valuabvle when you are just doing a copy. 
However, copy is used enought in dumps that the exta word (the table
name) doesn't see to hurt.

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073
 


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

Предыдущее
От: Richard Huxton
Дата:
Сообщение: Re: 2-phase commit
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: initdb failure (was Re: [GENERAL] sequence's plpgsql)