Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.tools -> Re: help : about long datatype

Re: help : about long datatype

From: <xmark.powell_at_eds.com.x>
Date: 28 Mar 2001 14:16:58 GMT
Message-ID: <99sroq$d9o$1@news.netmar.com>

In article <99p9o8$qv8$1_at_charm.magnus.acs.ohio-state.edu>, C.K. <cklok2000_at_sinaman.com> writes:
>i'm looking for solution for this asap
>i'm trying to make a trigger which will send some records to table B
>after/before insert to table A
> however, one of the field of table A must be a "LONG" datatype, while that
>field in table B must be a "VARCHAR2" datatype for some reason.
> can you help me out of how to convert it or whatever way i can archieve
>that goal?
> i will appreicate it
>

Well a varchar2 in pl/sql can hold up to 32K so as long as the actual data in the long column is <= to 32K you can select the long into the pl/sql variable then substring the pl/sql variable into the table B varchar2 column. But if your table A long column contains more than 4000 bytes of information you are losing data.

You should consider converting the long column into a LOB.

Received on Wed Mar 28 2001 - 08:16:58 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US