Import/Export CSV from SQLite from C# code

前端 未结 2 415
Happy的楠姐
Happy的楠姐 2021-01-05 13:01

I am trying to figure out an eazy way to load CSV file into SQLite DB using System.Data.SQLite

I saw commandline way to do that i.e .Import mydata.csv mytable<

相关标签:
2条回答
  • 2021-01-05 13:11

    You could use the file helpers library if you want also.And well use the ado.net functionality too.

    0 讨论(0)
  • 2021-01-05 13:25

    you can create OleDbConnection to CSV file (just google it, it is very easy) then load rows to DataSet, then put that dataset into Sqlite by SqliteConnection. Few lines of code.

    0 讨论(0)
提交回复
热议问题