| From: | " Sonia Sanchez Diaz" <sonny(at)piaget(dot)dgsca(dot)unam(dot)mx> |
|---|---|
| To: | <pgsql-general(at)postgresql(dot)org> |
| Subject: | Serial types |
| Date: | 2002-02-15 22:52:47 |
| Message-ID: | 59376.132.248.225.24.1013813567.squirrel@entren.dgsca.unam.mx |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
How Can I restart the values of a serial type field...??
I mean, I have a table with id_user defined as serial type, if a delete the
data from this table and insert new data the field id_user will start the
counter from the last record it had saved...
So... I want the new records insert into the table begins again with 1.
I used alter table <table> alter id_user set default 1;
But, only I could insert one record with number 1.
Thanks for your answers.
Sonny
--
Los amigos verdaderos se hieren con verdades,
para no perderse con mentiras
---
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Vince Vielhaber | 2002-02-15 23:41:51 | Re: Powered by PostgreSQL logos/icons/images... |
| Previous Message | Sean Chittenden | 2002-02-15 22:40:04 | Powered by PostgreSQL logos/icons/images... |