dsxjot8620 2014-07-29 09:15
浏览 42
已采纳

用于此目的的Windows应用程序或Web应用程序

I have about 5000 csv file and I want to insert them in a sql server 2008 database.

I don't whether windows application or web application is better.

each csv file is simple a one row with 36 column that will be inserted in an one table in the database.

thanks for your help.

Update 1

This application will be used on a computer that can connect to the database, it is used by the admin just once, in order words, there are people who responsible to write these csv files, then all the files, come to me and I have to insert them in the database

Update 2

Thanks for the user who are trying to help me.

You gave me these options:

  1. bcp

  2. SqlBulkCopy

  3. Windows service

what is the best please? I told you all the requirements, which are very simple.

  • 写回答

2条回答 默认 最新

  • drkwpgrdb092239314 2014-07-29 09:18
    关注

    Depends how you want to use it - if you want to deploy to lots of people so they can upload a file and process it into a database, make it web.

    If on the other hand, you only have a couple of users which you can easily deploy an app to, there is a lot less infrastructure required to write it as an app.

    Sounds to me, you want to automate the mass loading of lots of files, so windows app is jumping out at me.

    All depends on what the overall requirements are.

    Based on your edit, write a win app that uses a folder enumeration, reads the records and passes to a SqlBulkCopy object.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥20 sub地址DHCP问题
  • ¥15 delta降尺度计算的一些细节,有偿
  • ¥15 Arduino红外遥控代码有问题
  • ¥15 数值计算离散正交多项式
  • ¥30 数值计算均差系数编程
  • ¥15 redis-full-check比较 两个集群的数据出错
  • ¥15 Matlab编程问题
  • ¥15 训练的多模态特征融合模型准确度很低怎么办
  • ¥15 kylin启动报错log4j类冲突
  • ¥15 超声波模块测距控制点灯,灯的闪烁很不稳定,经过调试发现测的距离偏大