enumerating rows

From: Kovacs Zoltan <kovacsz(at)pc10(dot)radnoti-szeged(dot)sulinet(dot)hu>
To: pgsql-sql(at)postgresql(dot)org
Subject: enumerating rows
Date: 2001-04-11 12:02:34
Message-ID: Pine.LNX.4.21.0104111357510.3543-100000@pc10.radnoti-szeged.sulinet.hu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Maybe a trivial question, maybe it's foreign from SQL, I'dont know...
How to add a column which stands for the row number in each row of the
result? E.g.:

row_no | column1 | column2 | ...
-------+---------+---------+ ...
1 | datum11 | datum12 | ...
2 | datum21 | datum22 | ...
... | ... | ... | ...

I didn't find anything in the docs.

TIA, Zoltan

--
Kov\'acs, Zolt\'an
kovacsz(at)pc10(dot)radnoti-szeged(dot)sulinet(dot)hu
http://www.math.u-szeged.hu/~kovzol
ftp://pc10.radnoti-szeged.sulinet.hu/home/kovacsz

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Oliver Elphick 2001-04-11 12:14:24 Re: Concatenate fields
Previous Message Oliver Elphick 2001-04-11 11:59:35 Re: problem with copy command