pg_dump & restore question regarding creating with serial

Поиск
Список
Период
Сортировка
От Pam Wampler
Тема pg_dump & restore question regarding creating with serial
Дата
Msg-id 2E4528861499D41199D200A0C9B15BC001D5065E@FRISTX
обсуждение исходный текст
Ответы Re: pg_dump & restore question regarding creating with serial  (Josh Berkus <josh@agliodbs.com>)
Список pgsql-novice
Hi
I am trying to make a copy of one database to another.  I have done the
pg_dump and then psql -f filename into new database-- but when I look at a
table that has been created with (id serial primary key) -- -- on the new
database the id does not start at 1 but the number greater than the last id
of the original table.  How can I make the id start at 1  -- I would have
thought that the initial load into the new database would be an exact
replica of the original database?

When I do \d for the table I see this:

 id           | integer                     | not null default
nextval('"inv_trans_id_seq"'::text)

thanks

Pam Wampler

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

Предыдущее
От: "Josh Berkus"
Дата:
Сообщение: Re: help about service postgres
Следующее
От: Josh Berkus
Дата:
Сообщение: Re: pg_dump & restore question regarding creating with serial