Re: insert/select LONG

From: Joe Barger <joeb_at_sequent.com>
Date: 19 Apr 93 17:03:53 GMT
Message-ID: <1993Apr19.170353.27879_at_sequent.com>


In article <1993Apr17.204808.2740_at_telxon.mis.telxon.com> rbasi_at_teleng.eng.telxon.com (Richard Basile) writes:
>NEVER SAY DIE!!! There has to be a way!
>
>I have a table with a LONG field. The data for this table is in
>another table. I can't do:
>
>insert into tableA (fld1, fld2, fld3long)
>select fldA, fldB, fldClong
>from tableB;
>
>So, how do I get long data from one table to another? I don't care if
>I have to stand on my tounge, there has to be a way to do this.
>
[sig deleted]

There is a way. I was just struggling though the same situation last week. When I got real desparate, I logged into the Oracle RTSS bulletin board and found a lead (see bulletin 99288.751, Using Long Datatype, by Robert Suess, dated June 7, 1990). It states the limitation you found and suggests the SQL*Plus COPY command. After some experimentation, I got it to work. Here is one way to solve the above problem:

SQL> copy from scott/tiger_at_database -
> create tableA (fld1, fld2, fld3long) -
> using select fldA, fldB, fldClong from tableB

Be sure to set "long" to a large enough value as longer data is truncated. See "SQL*Plus User's Guide and Reference", chapter 5 for the details.

I'd be interested in other solutions to this problem. Received on Mon Apr 19 1993 - 19:03:53 CEST

Original text of this message