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: loading data from flat file into oracle table.

Re: loading data from flat file into oracle table.

From: DA Morgan <damorgan_at_psoug.org>
Date: Fri, 19 Jan 2007 08:27:27 -0800
Message-ID: <1169224043.787028@bubbleator.drizzle.com>


Mark D Powell wrote:

> 
> On Jan 19, 9:18 am, "What's in a namespace" <what..._at_xs4all.nl> wrote:

>> <v.so..._at_gmail.com> schreef in berichtnews:1169211516.698151.152330_at_m58g2000cwm.googlegroups.com...
>>
>>
>>
>>
>>
>>> Hi,
>>> I'm new to DPL/OCI/OCCI.I'm trying to load data from flat file into
>>> table.
>>> 1)Connection to db(tested by inserting rows programatically)
>>> 2)Reading a dat file in E:\\test.dat which has tab seperated values
>>> into double dim array
>>> 3)allocating direct path context handle and setting attributes
>>> 4) allocating direct path column array handle using OCIHandleAlloc
>>> 3)setting the array created as direct path column array (dpca)
>>> OCIDirPathColArrayEntrySet
>>> Now that at the point,direct path stream (dpstream) handle is to be
>>> allocated and used to convert dpca into dpstream, OCIHandleAlloc is
>>> failing with ORA-24316: illegal handle type .
>>> So from that point everything is failing.
>>> Pleasae help me out ,...Take a look at External Tables!- Hide quoted text -- Show quoted text -
> 
> 
> If the job is to be triggered from outside the database then why not
> just use sqlldr utility?  If you want to trigger the task from within
> the database then use the mentioned External table feature (which is an
> interface to sqlldr).
> 
> For OCI coding check the manuals and see if you can find an example to
> compare to.
> 
> HTH -- Mark D Powell --

Note: With 10g you can trigger SQL*Loader from inside the database using the DBMS_SCHEDULER package.

-- 
Daniel A. Morgan
University of Washington
damorgan_at_x.washington.edu
(replace x with u to respond)
Puget Sound Oracle Users Group
www.psoug.org
Received on Fri Jan 19 2007 - 10:27:27 CST

Original text of this message

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