From: | Guillaume Lelarge <guillaume(at)lelarge(dot)info> |
---|---|
To: | David Leikis <David(dot)Leikis(at)sdl(dot)usu(dot)edu> |
Cc: | "pgadmin-support(at)postgresql(dot)org" <pgadmin-support(at)postgresql(dot)org> |
Subject: | Re: pgAdminII support question |
Date: | 2010-01-14 20:49:32 |
Message-ID: | 4B4F835C.80804@lelarge.info |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgadmin-support |
Le 07/12/2009 18:09, David Leikis a écrit :
> I am trying to create auto-incrementing of the Primary Key within each record by using sequences.
>
> Sometimes I can get the "add - sequence" to work by creating it with the name "tablename_columnname_seq".
>
> There are many other times that this doesn't work. (The table create SQL doesn't show up with the 'serial' command word in the column creation.)
>
> The sequence name is there, but it doesn't seem to 'make connection' to that table/column.
>
> I am using pgAdmin version 1.8.4 and PostGres version 8.3 in Winxp setting.
>
> Some solution to this would be very helpful, please.
>
Usually, you should use the serial datatype. It'll automatically create
a sequence and link it to your column default value.
--
Guillaume.
http://www.postgresqlfr.org
http://dalibo.com
From | Date | Subject | |
---|---|---|---|
Next Message | Rathod, Aashish | 2010-01-14 21:42:30 | Re: can't get pgpass.conf to work with pgagent |
Previous Message | Guillaume Lelarge | 2010-01-14 20:47:05 | Re: can't get pgpass.conf to work with pgagent |