Re: COPY and sequences

Поиск
Список
Период
Сортировка
От Neil Conway
Тема Re: COPY and sequences
Дата
Msg-id 87u15cxbe8.fsf@mailbox.samurai.com
обсуждение исходный текст
Ответ на COPY and sequences  ("Przemysław" <przemyslaw.slupkowski@euro.coig.pl>)
Список pgsql-bugs
"Przemys=B3aw" <przemyslaw.slupkowski@euro.coig.pl> writes:
> Hello
> I dont know is this a bug but when I use COPY to load data into table
> sequence of the primary key in this table have always start value =3D
> 1.

Doesn't sound like a bug. If the input data for COPY does not include
PK values, you should not include the PK column in the COPY's column
list, and make sure the PK column's default value gets the nextval()
from the sequence.

-Neil

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

Предыдущее
От: Neil Conway
Дата:
Сообщение: Re: before trigger doesn't, on insert of too long data
Следующее
От: Neil Conway
Дата:
Сообщение: Re: pg_dumpall does not save CREATE permission on databases