The text of this article is not in this database — only its details are. The old site it was published on is gone, but the Internet Archive kept a copy: Fastest way to populate datatable from database using IDataReader
Join the conversation! Your thoughts help the community grow.
Sign in to leave a comment
It is the same account you read, post and publish with — and you will come straight back to this page.

ורדה שוויבלPosted Jul 16, 2019, 3:26 AM
You saved my day, Thank
Sr KarthigaPosted Feb 26, 2016, 9:14 AM
good one
Sr KarthigaPosted Feb 26, 2016, 9:14 AM
nice explanation
Amit ChoudharyPosted Oct 25, 2012, 6:31 AM
Thanks for finding the Errata in the code. I appreciate that. For comparing performance we already have debt on these two. Check'em out here and do mention you findings, it will give others to re-think about Adpater vs Reader: http://stackoverflow.com/questions/1676753/sqldataadapter-vs-sqldatareader http://social.msdn.microsoft.com/Forums/en-US/adodotnetdataproviders/thread/c2d762fd-f4a0-4875-8bb8-42f7480e97c8/ :)
Atul PandeyPosted Oct 10, 2012, 5:21 AM
Oh My God! I tested and the result is opposite! SqlDataAdapter is FASTER than IdataReader. (I tested with 500 records, 10000 records and 600,000 records)
Atul PandeyPosted Oct 10, 2012, 4:55 AM
Thank Amit Choudhary for your helpful article! But i want to discuss a litle about the row: for (int i = 0; i < resultTable.Columns.Count - 1; i++) { dataRow[i] = dataReader[i]; } I think that it'd be better if for (int i = 0; i < resultTable.Columns.Count; i++)
Amit ChoudharyPosted Oct 7, 2011, 2:07 AM
It was Around 500 + records against the Product table of AdventureWorks DB. Well if you want I'll run it against the large records and will update the stats.
Javeed M ShaikhPosted Oct 6, 2011, 5:20 PM
Your test was for how many number of records?