VS2008 VB.NET将数据从列表框移动到SQL [英] VS2008 VB.NET Moving Data from ListBox to SQL

查看:148
本文介绍了VS2008 VB.NET将数据从列表框移动到SQL的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Ok Guys或Gals,
我是一名控制工程师,在这个项目上戴着很多帽子.万能的杰克...无主.

我想将一个csv文本字符串移动到我的sql数据库中.考虑到记录中有120多个字段,我正在尝试确定移动数据的最佳方法.当然,csv字符串中的顺序数据对应于这些字段.大部分数据为0和1.我知道有几种方法可以做到这一点,但我想我会由你们来运行,看看是否有人知道最好的快捷方式.

Ok Guys or Gals,
I am a controls engineer wearing lots of hats on this project. Jack of all trades... Master of none.

I want to move a csv text string to my sql database. I am trying to determine the best way to move the data considering there are over 120 fields in the record. Of course the sequential data in the csv string corresponds to the fields. Most of the data is 0s, and 1s. I know there are several ways to do this but I thought I would run it by you guys to see if someone knows of the best shortcut.

推荐答案

在代码中或使用工具?

我个人只是使​​用SQL导入数据向导.
In code or using tools?

Personally I''d just use the SQL Import data wizard.


您好,
CP上有各种解析器.对于解析纯CSV文件,我使用 Sebastien Loriens CSV解析器 [ Andrew Rissing的通用平面文件解析器 [ ^ ]

编码愉快
Hi there
There are various parsers available on CP. For parsing pure CSV files I use Sebastien Loriens CSV Parser[^]

Otherwise for general Flat File parsing I use Andrew Rissing''s Generic Flat File Parser[^]

Happy Coding


好吧...我还在找.我可以将csv解析为结构化数组,然后使用SQL语句将数组的内容移到记录中吗?我将尝试自己回答这个问题,但稍后会再回来查看评论.
OK... I''m still looking. Can I parse the csv to a structured array and then use a SQL statement to move the contents of the array into a record? I will try to answer this myself but will check back shortly for comments.


这篇关于VS2008 VB.NET将数据从列表框移动到SQL的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆