原文:C# ASP.NET CSV文件导入数据库 using System; using System.Collections.Generic; using System.Text; using System.Data; using System.Data.OleDb; using System.Data.Sql; using System.Data.SqlClient; using System.IO; namespace HPRSP.CommonDataObject { public cla
并行进程怎么使用? import os import sys import time def processFunc(i): time.sleep(10-i) print i if __name__=='__main__': from multiprocessing import Pool pool=Pool() for i in range(0,10): print i print '----------------split line-----------------' for i in r
先打开CSV文件查看第一行有哪些字段,然后新建数据库,新建表.(若字段内容很多建议类型text,如果设成char后续会报错) 命令如下: load data infile '路径XXXX.csv' into table 表名 fields terminated by ',' optionally enclosed by '"' escaped by '"' lines terminated by '\r\n'; 示意图: 搞定!
USE LHJTest create table #temp6//创建临时表 ( A nvarchar(max) NOT NULL, B nvarchar(max), C nvarchar(max), D nvarchar(max),E nvarchar(max), F nvarchar(max),G nvarchar(max), H nvarchar(max),I nvarchar(max), J nvarchar(max),K nvarchar(max), L nvarchar(max)