2008年7月14日

c#中高效的excel导入sqlserver的方法

摘要: 将oledb读取的excel数据快速插入的sqlserver中,很多人通过循环来拼接sql,这样做不但容易出错而且效率低下,最好的办法是使用bcp,也就是System.Data.SqlClient.SqlBulkCopy 类来实现。不但速度快,而且代码简单,下面测试代码导入一个6万多条数据的she... 阅读全文

posted @ 2008-07-14 19:43 代码王子 阅读(99) 评论(0) 推荐(0)

Wininetdll函数库:根据url获取缓存文件

摘要: using System; using System.Collections.Generic; using System.Text; using System.Runtime.InteropServices; namespace ConsoleApplication34 { class P... 阅读全文

posted @ 2008-07-14 15:14 代码王子 阅读(144) 评论(0) 推荐(0)

导航