Re: Write numbers in binary form with UTL_FILE?

From: Michael Rothwell <marothwell_at_yahoo.com>
Date: Tue, 20 Mar 2001 17:32:07 -0800
Message-ID: <3AB80497.E886636D_at_yahoo.com>


I never found a way to do this. I ended up using Pro*C, and that even took a long time to figure out, but I got it done. I you find a way using UTL_FILE, please let me know.

Michael

Stephen Doom wrote:
>
> Anyone with experience writing binary data, to flat text Operating
> System files?
>
> We're familiar with UTL_FILE, but it seems to convert everything to
> character before writing out.
>
> We have a need on an EBCDIC platform for an extract from Oracle. That
> file needs to have binary data (that's COMP or COMP-3 in COBOL) within
> it. The binary number we need (which will always positive), will
> contain the LENGTH of a corresponding VARCHAR2 column.
>
> The IBM needs it this way so it can load VARCHAR2 data from Oracle,
> into VARCHAR2 data in DB/2. I guess DB/2 isn't smart enough to parse
> the string and figure it out on it's own.
>
> And we don't have any tools to get them to talk to one another.
>
> So short of a solution within DB/2 (to eliminate that requirement) or
> Oracle, we'll need to resort to COBOL to re-create the file on the IBM
> side, using a CHAR field in the Oracle extract containing the length,
> which we'll then convert to COMP or COMP-3 on the IBM before the load
> to DB/2.
>
> Kindly reply, if you would, to pennine.s_at_bcbsri.org, as I don't get
> out to the group that often.
>
> Posted Via Usenet.com Premium Usenet Newsgroup Services
> ----------------------------------------------------------
> ** SPEED ** RETENTION ** COMPLETION ** ANONYMITY **
> ----------------------------------------------------------
> http://www.usenet.com
Received on Wed Mar 21 2001 - 02:32:07 CET

Original text of this message