MySqlDataAdapter or MySqlDataReader for bulk transfer?
- by Jeff Meatball Yang
I'm using the MySql connector for .NET to copy data from MySql servers to SQL Server 2008.
Has anyone experienced better performance using one of the following, versus the other?
DataAdapter and calling Fill to a DataTable in chunks of 500
DataReader.Read to a DataTable in a loop of 500
I am then using SqlBulkCopy to load the 500 DataTable rows, then continue looping until the MySql record set is completely transferred.
I am primarily concerned with using a reasonable amount of memory and completing in a short amount of time.
Any help would be appreciated!