Re: PostgreSQL 9.1 pg_dump setval() sets wrong value
| От | Adrian Klaver | 
|---|---|
| Тема | Re: PostgreSQL 9.1 pg_dump setval() sets wrong value | 
| Дата | |
| Msg-id | 201112280707.32363.adrian.klaver@gmail.com обсуждение исходный текст | 
| Ответ на | Re: PostgreSQL 9.1 pg_dump setval() sets wrong value (Greg Donald <gdonald@gmail.com>) | 
| Ответы | Re: PostgreSQL 9.1 pg_dump setval() sets wrong value | 
| Список | pgsql-general | 
On Wednesday, December 28, 2011 6:54:54 am Greg Donald wrote:
> > Are you
> > sure that the sequence is being used to insert those values into the
> > table?
>
> When I insert a new row into either of the tables I previously
> described, the sequence 'Current value' increments by one.  When I use
> pg_dump to backup the database most of the setval() calls in my SQL
> file have a '1', like this:
>
> SELECT pg_catalog.setval('company_id_seq', 1, false);
>
> Some do not have a '1', some are actually set correctly.
So how are the sequences being tied to the tables? In your previous post the
table definitions did not show a SERIAL type or a default of nextval().
>
>
> Thanks.
--
Adrian Klaver
adrian.klaver@gmail.com
		
	В списке pgsql-general по дате отправления: