Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Q:SQL:How to update pagenumbers
Hi Ralf !
Try this:
update your_table a
set page = (select count(*)
from your_table b where b.time_stamp <= a.time_stamp);
HTH Angelo.
Ralf Bender wrote:
>
> Hello *.*
> i've got a high problem in my little opinion.
> there is a table like this :
>
> company number page timestamp(MM.DD.YY)
> 11 123 1 07.09.98
> 11 123 2 07.09.98
> 11 123 1 09.09.98
> 11 123 2 09.09.98
>
> now, i must renumber the page of the youngest records.
> the table must look like this :
>
> company number page timestamp(MM.DD.YY)
> 11 123 1 07.09.98
> 11 123 2 07.09.98
> 11 123 3 09.09.98
> 11 123 4 09.09.98
>
> Is there somebody who can help me ?
> --
>
> bye
> Ralf Bender
> (mailto:Ralf.Bender_at_wolnet.de)
Received on Wed Oct 14 1998 - 09:56:04 CDT