Skip site navigation (1) Skip section navigation (2)

'SERIAL' in pgsql

From: Archana K N <archanakknn(at)gmail(dot)com>
To: pgsql-php(at)postgresql(dot)org
Subject: 'SERIAL' in pgsql
Date: 2012-07-16 09:23:55
Message-ID: CACa6=i01-C93NyY_rvhwsi9qaU6EFSTPgnvJZ1Tq7cE3ZQaEvA@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-php
Hello,

  I have a database whose primary key is 'slno' and which is an auto
increment field.I inserted some values to database say upto
" slno - 5". Then I deleted the row with 'slno' 3 . Now I want the to shift
all the rows upward ie 4th row should be third and its 'slno' should also
be 3. I heard that this is not possible.Is there a way to do this other
than to move all rows to another database except the slno.

-- 
-------------------
regards
archana
--------------------

Responses

pgsql-php by date

Next:From: Thom BrownDate: 2012-07-16 09:56:30
Subject: Re: 'SERIAL' in pgsql
Previous:From: Archana K NDate: 2012-06-05 10:17:52
Subject: Re: Problem in importing database

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group