Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.tools -> Re: adjust seq

Re: adjust seq

From: Niall Litchfield <n-litchfield_at_audit-commission.gov.uk>
Date: Wed, 6 Sep 2000 16:42:56 +0100
Message-ID: <8p5om1$atg$1@soap.pipex.net>

Why do you wish to do this? The table you have looks like it has a primary key , generated by means of a sequence. If this is the case why does the PK value need to be change at all.

--
Niall Litchfield
Oracle DBA
Audit Commission UK
<eastking_at_my-deja.com> wrote in message news:8ov4vf$n3o$1_at_nnrp1.deja.com...

> Hi , every one here.
>
> I have a table as following
>
> Seq value
> -----------
> 1 aaa
> 2 bbb
> 3 ccc
>
> When I delete the second record , I want it be adjust to be as following
>
> Seq value
> -----------
> 1 aaa
> 2 ccc
>
> As you can see , the '3' has been changed to '2', The Seq had been
> rearranged. I do not want to use trigger to achieve it.
>
> How can I do that? of course, one SQL is most approved.
>
> Thanks a lot
>
>
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Received on Wed Sep 06 2000 - 10:42:56 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US