public void Insert()
 {
     BulkCopy.BulkCopyTimeout      = BulkCopySettings.BulkCopyTimeout;
     BulkCopy.BatchSize            = BulkCopySettings.BatchSize;
     BulkCopy.DestinationTableName = TableName;
     Connection.Open();
     BulkCopy.WriteToServer(DataTable);
     Connection.Close();
 }
Example #2
0
        public void WriteToServer()
        {
            if (Connection.State != ConnectionState.Open)
            {
                Connection.Open();
            }

            BulkCopy.WriteToServer(InternalTable);
        }