Home » Developer & Programmer » Precompilers, OCI & OCCI » loading data from flat file into remote oracle table
loading data from flat file into remote oracle table [message #215390] Mon, 22 January 2007 01:24
sorna
Messages: 1
Registered: January 2007
Junior Member
Hi
I'm trying to load data from flat file into table using OCI OCCI DPL.
I'm able to connect to remote datad=base where data is to be copied,read data from flat file in client machine into array,put them in direct path col array.
Now that when allocating handle for stream it gives me error (illegal handle type.)
error = OCIHandleAlloc((dvoid *)dpctx, (dvoid **)&dpstr,(ub4)OCI_HTYPE_DIRPATH_STREAM, (size_t)0,(dvoid **)0);
As i debugged i found that error returned is -1.
I'm not sure if i'm doing the right thing.
Im doing the following
1)connecting to remote database
2)reading flat file data into array
3)allocating handles for direct path context ,colarray.setting column,rowcount,table name attributes.
4)OCIDirPathColArrayEntrySet
5)allocating stream ------- fails
6)so following stream functions,loadind,finish all are failing.


I guess i'm missing some attributes.It will be great if there are some inputs on how data in flat file in client can be put into a remote database table .

Previous Topic: How to cancel my query in an occi program?
Next Topic: libwtc9.so, needed by libclntsh.so, not found (try using -rpath or -rpath)
Goto Forum:
  


Current Time: Thu Mar 28 10:39:47 CDT 2024