dbTalk Databases Forums  

Which is Better -- Array Binding or Insert DataSet?

comp.database.oracle comp.database.oracle


Discuss Which is Better -- Array Binding or Insert DataSet? in the comp.database.oracle forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
goldenorb82
 
Posts: n/a

Default Which is Better -- Array Binding or Insert DataSet? - 07-30-2004 , 03:30 PM






Hello,

I am a newbie trying to create an API written in C# that connects to
an oracle database and reads/inserts records. right now, i've got it
inserting records one at a time, but i need to be able to insert maybe
5-6 thousand records at one time. The data is not currently in a
database, it is in an array i have in the C# code. I have done some
reading on the subject, and have narrowed down my options -- i can:

1. Bulk Bind
2. Array Bind
3. Insert DataSet

I'm shady on all three of these topics, but if someone could point me
in the right direction; which would be the fastest, most efficient,
that would be great. thanks

Reply With Quote
  #2  
Old   
Jim Kennedy
 
Posts: n/a

Default Re: Which is Better -- Array Binding or Insert DataSet? - 07-30-2004 , 11:19 PM







"goldenorb82" <goldenorb82 (AT) gmail (DOT) com> wrote

Quote:
Hello,

I am a newbie trying to create an API written in C# that connects to
an oracle database and reads/inserts records. right now, i've got it
inserting records one at a time, but i need to be able to insert maybe
5-6 thousand records at one time. The data is not currently in a
database, it is in an array i have in the C# code. I have done some
reading on the subject, and have narrowed down my options -- i can:

1. Bulk Bind
2. Array Bind
3. Insert DataSet

I'm shady on all three of these topics, but if someone could point me
in the right direction; which would be the fastest, most efficient,
that would be great. thanks
Use Oracle's OCI api and do an array insert using bind variables.
Jim




Reply With Quote
  #3  
Old   
Philippe Valentin
 
Posts: n/a

Default Re: Which is Better -- Array Binding or Insert DataSet? - 07-30-2004 , 11:25 PM



Hi,

An easy way to do your load is:
1. create an Oracle directory
2. Create an external table that matches your external datafile
organisation
3. load from the exernal table (as you would from a "local" table)

There is an excellent example in the documentation (SQL and PL/SQL
syntax, search for "create table" and then ctrl-F "external": your
whole solution is there)
Have fun.
Ph.


goldenorb82 (AT) gmail (DOT) com (goldenorb82) wrote in message news:<231354a1.0407301230.d74f242 (AT) posting (DOT) google.com>...
Quote:
Hello,

I am a newbie trying to create an API written in C# that connects to
an oracle database and reads/inserts records. right now, i've got it
inserting records one at a time, but i need to be able to insert maybe
5-6 thousand records at one time. The data is not currently in a
database, it is in an array i have in the C# code. I have done some
reading on the subject, and have narrowed down my options -- i can:

1. Bulk Bind
2. Array Bind
3. Insert DataSet

I'm shady on all three of these topics, but if someone could point me
in the right direction; which would be the fastest, most efficient,
that would be great. thanks

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.