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

Home -> Community -> Usenet -> c.d.o.misc -> Re: sqlload CTL for fixed-width VARRAY?

Re: sqlload CTL for fixed-width VARRAY?

From: Ed Prochak <prochak_at_my-deja.com>
Date: Fri, 24 Dec 1999 06:37:23 GMT
Message-ID: <83v47p$nal$1@nnrp1.deja.com>


In article <r8r84.21$WC4.4419_at_news.wenet.net>,   sorry_at_spam.invalid wrote:
>
> So, from the lack of responses, I'm guessing SQL Loader can't load
arrays
> from fixed-width, undelimited fields...

Lack of response in this case only meant, there wasn't a response. Such things happen in news groups. Sometimes we wait to see if someone else will answer. in this case no one did until now. I hope you still check back because there may be other responses beside mine.

Note that your invalid email address in the header does not mean the spam bots cannot parse out the email address you provided in your signature. You only succeeded in making it harder for me and others to contact you.

Oracle's SQL*Loader can handle fixed length fields easily. You specify the field position by character position, like:

   ...
   color (31-35),
   noun (36-40),
   ...

would load 'brown' in the color column and 'fox ' in the noun column. Rest of control file information can be more easily found in the manuals. Did you look there?

>
> Last week I wrote:
>
> > We're moving from System 1032 (a wonderful database system) on a
> > VAX/VMS system to Oracle 8.0.5 on an RS/6000 AIX box. We have LOTS
of
> > data in array fields, and for now want to keep them that way. Can
> > anyone provide me with an appropriate syntax for the SQL Loader
> > control file, given a fixed-width, undelimited ASCII data input
file?
> > For a simple example, how would one write the control file for
> > something like:
>
> > create or replace type NARRAY as varray(10) of number;
> > create or replace type CARRAY as varray(10) of varchar(5);
>
> > create table DUMMY
> > (some_numbers NARRAY
> > ,some_letters CARRAY
> > );
>
> > and an input file consisting of:
>
> > 12121212121212121212the quickbrownfox jumpsover the lazy dogs
back.
> > 1 2 3 4 5 6 7 8 9

0abcdeabcdeabcdeabcdeabcdeabcdeabcdeabcdeabcdeabcde
>
> > (some_numbers always being two digits, and some_letters always being
> > left-justified, space-padded, 5-character text, for this example.)
>
> > Thanks!
>
> --
> --
> ======== Physical ========================== Virtual



> Kevin Cole | E-mail: kjcole_at_gallux.gallaudet.edu
> P.O. Box 2739 | WWW:

http://www.gallaudet.edu/~kjcole/Bike/
> Washington, D.C. 20013 | Voice: (202) 234-0213
>



> "If they give you ruled paper, write the other way."
>

--
Ed Prochak
Magic Interface, Ltd.
ORACLE Development, conversions, training and support 440-498-3700 magic_at_interfacefamily.com

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Fri Dec 24 1999 - 00:37:23 CST

Original text of this message

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