Search Postgresql Archives

Re: Remove Modifiers on Table

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, May 17, 2011 at 12:12 PM, Raymond O'Donnell <rod@xxxxxx> wrote:
> Well, the SERIAL pseudo-type creates the sequence, associates it with the
> column, and sets a DEFAULT on the column which executes the nextval()
> function on the sequence - all in one fell swoop. Read all about it here:
>
> http://www.postgresql.org/docs/9.0/static/datatype-numeric.html#DATATYPE-SERIAL

Wow I had no idea. So I do NOT need to manually create a sequence with:

CREATE SEQUENCE blah_id_seq;

And instead I can just use the SERIAL data type, unless I understood
that wrong. I'm going to read up on the URL you provided.

Thank you so much!

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux