Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Update in a dynamic process
Hi!
Maybe this will help:
http://otn.oracle.com/docs/products/oracle8i/doc_library/817_doc/appdev.817/
a77069/10_dynam.htm
Boris
"arnaud herve" <dillonais_at_wanadoo.fr> wrote in message
news:aobc3g$t37$1_at_news-reader11.wanadoo.fr...
> I've a table T like that
> X Y
> -------
> A NULL
> NULL C
> D E
> F NULL
>
> My Problem.
> I want to replace values equal to NULL by the value which follow them
> In my case, I'll get.
> A C
> D C
> D E
> F NULL
> I used a curosr but how to make a dynamic update?
>
> according to me,It would be like
> _____________________________________
> .........
> for i in 1..sql%rowcount-1 loop
> if X is null
> update T set X = select X from T
> where rownum = i+1;
> end loop;
> ..........
> _________________________________________
>
> it's a sample of code, I know a dirty code, but simply to show you, what
I
> want to get.
>
>
>
Received on Sun Oct 13 2002 - 03:59:41 CDT