diff --git a/src/ChoETL/Common/ChoUtility.cs b/src/ChoETL/Common/ChoUtility.cs index 078b2b50..a75ea7a1 100644 --- a/src/ChoETL/Common/ChoUtility.cs +++ b/src/ChoETL/Common/ChoUtility.cs @@ -2251,8 +2251,9 @@ private static void Bcp(this IDataReader dr, SqlBulkCopy bcp, string tableName, }; } - if (columnMappings == null || columnMappings.Count == 0) + if (columnMappings != null && columnMappings.Count > 0) { + bcp.ColumnMappings.Clear(); foreach (KeyValuePair keyValuePair in columnMappings) bcp.ColumnMappings.Add(keyValuePair.Key, keyValuePair.Value); }