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: SQL*Loader Question

Re: SQL*Loader Question

From: Bill Manry <B.Manry_at_upsizeme.us.oracle.com>
Date: 1997/05/29
Message-ID: <5mksit$23k$1@inet16.us.oracle.com>#1/1

Joel Rudloff (j-rudl_at_cafe.tc.umn.edu) wrote:
>I've run into a problem using SQL*Loader and being new to both Oracle and
>Unix, I'm wondering about the best approach to fix it. I have an unloaded
>table from DB2 (MVS) that I've ftp'ed to an RS 6000 running AIX. Within
>that file are varchar fields, each preceeded with a length field stored as
>packed decimal. Certain values within the length field, when seperated
>into characters, produce the same value as a line-feed character. When
>Oracle sees that character, it reacts as if it reached the end of one
>record and the beginning of another. I end up with incomplete rows in the
>table. Do I have to change the input file (change all packed fields to
>display) or are there other ways around this?

Strictly speaking, you need to unload your DB2/MVS data in all-character form in order for UNIX SQL*Loader to handle it. You can let ftp do the EBCDIC->ASCII translation or you can ftp in binary and use SQL*Loader's CHARACTERSET option to do the translation. But there are a variety of problems involved in sending "native" S/370 numbers such as packed decimal over to UNIX, and you should avoid doing that.

If moving DB2/MVS data to Oracle is something you do very often, you should consider getting one of Oracle's Transparent Gateway products. These let you copy DB2 data into Oracle as simply as a SQL INSERT statement. If you want the Oracle version of your DB2 data kept current, take a look at Oracle's Heterogenous Replication products.

/b

--
Bill Manry  -  IBM Products Division  -  Oracle Corporation
These are my opinions, not necessarily Oracle's.
Remove "." from "B.Manry" to email me.
Received on Thu May 29 1997 - 00:00:00 CDT

Original text of this message

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