摘要: 特别注意 sqlbulkcopy.ColumnMappings.Add(dt.Columns[i].ColumnName, dt.Columns[i].ColumnName); 插入的时候列的顺序可以不一致,但名称和数据类型最好要保存一致。不一致时候,也能进行正确的转换,除了比如DataTime数据 阅读全文
posted @ 2017-03-02 11:27 甜菜波波 阅读(394) 评论(0) 推荐(0) 编辑
摘要: 1.所用类库有 Microsoft.Web.Infrastructure.dll 和WebActivator.dll 2.类代码如下 using System; using System.Collections.Generic; using System.Linq; using System.Tex 阅读全文
posted @ 2017-03-02 11:14 甜菜波波 阅读(315) 评论(0) 推荐(0) 编辑