Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Copying an Oracle Long/Long Raw column
On Wed, 28 Jul 1999 20:36:53 GMT, srjohns1024_at_my-deja.com wrote:
>We are currently using Oracle 7.x
>
>We need to duplicate a row containing a Long into the same table (only
>changing the primary key).
With pl/sql and the assumption that the long and long raw are under 32K then...
declare
l_long long;
begin
for c in ( select l from foo ) loop
insert into foo values ( seq.nextval, c.l );
end loop;
end;
... and ...
>
>We also need to duplicate a row containing a Long Raw into the same
>table (only changing the primary key).
declare
l_longraw long raw;
begin
for c in ( select lr from bar ) loop
insert into bar values ( seq.nextval, c.lr );
end loop;
end;
... should work just fine.
>
>Can anyone assist us with this problem?
hope this helps.
chris.
>
>
>Sent via Deja.com http://www.deja.com/
>Share what you know. Learn what you don't.
--
Christopher Beck
Oracle Corporation
clbeck_at_us.oracle.com
Reston, VA.
![]() |
![]() |