Todd,

You can't use Insert Into...As Select From... with Long or
Long Raw columns.

One solution that I've used is to write an anonymous PL/SQL
block that loops through a cursor on your source table,
capturing each source row in a PL/SQL record, then Inserting
into your target table using the Values clause - where the
Values are the fields in the PL/SQL record.  It's
row-at-a-time and a little slow maybe, but it works.

Hope it helps.

Jack

--------------------------------
Jack C. Applewhite
Database Administrator/Developer
OCP Oracle8 DBA
iNetProfit, Inc.
Austin, Texas
www.iNetProfit.com
[EMAIL PROTECTED]


-----Original Message-----
[EMAIL PROTECTED]
Sent: Monday, April 02, 2001 12:46 PM
To: Multiple recipients of list ORACLE-L



OK, I admit it. In 3 years as a DBA I haven't had to deal
with a single
LONG RAW column. BLOB, CLOB and BFILE yes LONG RAW, no. So
here is my
Monday morning challenge.

I had a database hose itself on Sunday. I rebuilt the
database, but it is
still misbehaving (looks like hardware). I can't get a clean
export. The
three schemas it holds are small. Therefore I thought I
would just write
the SQL to copy the schemas to a different DB on a different
box. The code
works great, until the damn LONG RAW column decended on my
plans like the
angel of death. This is a 3rd party app (of course).

The COPY command doesn't work and the docs aren't helping.
Does anyone have
any ideas that would help?

DBA> copy from atg_productivity/xxxxx@atgd -
> to atg_productivity/xxxxx@DBA -
> insert
dss_scenario_info(ID,SCENARIO_NAME,SCENARIO_STATUS,MODIFICAT
ION_TIME,SDL) -
> using select
ID,SCENARIO_NAME,SCENARIO_STATUS,MODIFICATION_TIME,SDL from
dss_scenario_info;

Array fetch/bind size is 1. (arraysize is 1)
Will commit after every array bind. (copycommit is 1)
Maximum long size is 30000. (long is 30000)

ERROR:
ORA-00932: inconsistent datatypes


TIA,
Todd Carlson
Oracle 8i Certified DBA
Bunge Corporation


-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Jack C. Applewhite
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- (858) 538-5051  FAX: (858) 538-5051
San Diego, California        -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

Reply via email to