Re: automatic numbering in a new column - Mailing list pgadmin-support

From Guillaume Lelarge
Subject Re: automatic numbering in a new column
Date
Msg-id 1314211948.2193.39.camel@localhost.localdomain
Whole thread Raw
In response to automatic numbering in a new column  (ppdcc@sapo.pt)
List pgadmin-support
A few comments before answering:
1. Don't top post. It makes it hard to read.
2. Reply to the list.
3. Choose your list more carefully. pgadmin-support is about pgAdmin  support, not about SQL.

This being said, I'll quickly answer your question...

On Wed, 2011-08-24 at 19:47 +0100, ppdcc@sapo.pt wrote:
> and how i do that?
> 
> cAN you make a example for me
> 

CREATE TABLE t1 (c1 serial, c2 text);

c1 will be automatically numbered if you don't set a value for it. Just
like this: INSERT INTO t1 (c2) VALUES ('hello');


-- 
Guillaume http://blog.guillaume.lelarge.info http://www.dalibo.com



pgadmin-support by date:

Previous
From: Guillaume Lelarge
Date:
Subject: Re: automatic numbering in a new column
Next
From: "Cuddihy, Joe"
Date:
Subject: admin