Re: SQL problem
Date: 2000/05/05
Message-ID: <8ev7iv$jf3$1_at_nnrp1.deja.com>#1/1
In article <8euvk9$mcg$1_at_pollux.ip-plus.net>,
"Tahar Bellem" <mohamedtahar.bellem_at_ctrceal.caisse-epargne.fr> wrote:
> Hi all,
>
> I had to create a table with this command :
>
> CREATE TABLE ... AS SELECT ... ;
>
> but if this is a LONG datatype in the create table , then this request
> doesn't work.
>
> exemple:
>
> SQL> desc pagereq
> Name Null? Type
> ------------------------------- -------- ----
> PAGEREQ_ID NOT NULL NUMBER(10)
> PAGEREQ_NUMPAGE NOT NULL NUMBER(3)
> PAGEREQ_DATA LONG
>
> SQL> CREATE TABLE pagereq_save AS SELECT * FROM pagereq;
>
> ERROR at line 1:
> ORA-00997: illegal use of LONG datatype
>
> Does anyone know what is the correct syntax ? Any help will be
appreciated.
>
> Thanks,
>
>
you cannot create a table as select with a LONG column.
You can create a table with all of the needed columns and use the sqlplus COPY command to get the data in there. See http://osi.oracle.com/~tkyte/Misc/MoveLongs.html for examples.
-- Thomas Kyte tkyte_at_us.oracle.com Oracle Service Industries http://osi.oracle.com/~tkyte/index.html -- Opinions are mine and do not necessarily reflect those of Oracle Corp Sent via Deja.com http://www.deja.com/ Before you buy.Received on Fri May 05 2000 - 00:00:00 CEST