Update to table en-mass, not one wimpy insert at a time...
Posted on 2007-08-05
I'd like to insert records into a table en-mass, rather than via a for loop, doing an INSERT statement for each row in an array. What's a better, faster, stronger, etc way? Thanks :) Andre
Records to insert were obtained by executing a SELECT on the source table OutScan.dbf, and outputting an array. This array was looped through, and an INSERT statement was done for each row.
ArrayList aScannedWeights = GetScannedWeightsFromOutscan(sBatch, sSequence);
for (int k=0; k<aScannedWeights.Count; k++)
string sScannedWeight = (string)aScannedWeights[k];
INSERT INTO phy_det (Track) values "SomeValue"