At the moment I'm selecting lots of rows out of a database table (75681), putting them into a datatable and then performing a foreach look on each row
foreach (DataRow row in dt.Rows)
{
//Updating record
}
I'm looking to try and split this down into chunks of 500 or 1000 for performance, but I'm unsure how to go about this?
Can I tell the foreach loop to process 500 at a time, or do I have to somehow split the datatable into 500 row chunks?
Hope the above makes sense!
Andrew