数据提取到csv [英] Data Extraction to csv

查看:180
本文介绍了数据提取到csv的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

对不起,我首先要声明我是一个编程傻瓜.我需要一些快速的帮助.是的,我想学习程序设计并且愿意学习,但是不知道我应该使用哪种语言.但是,我确实需要快速帮助.没事了!

好吧,假设我有成千上万个包含此类格式详细信息的文本文件,如何将其放入具有完整标题的csv中?
=============
公司名称:Data Wizard Pty Ltd

Hey all,

I''m sorry first and foremost i have to declare that i am a programming blockhead. I need some quick help in this. And yes i wanna take up programming and am willing to learn but have not a clue what language i should take. I do however need quick aid in this one. Here goes nothing!

Alright, supposing i have thousands of text files containing details in such format, how do i put it in a csv with complete header.
==============
Company Name: Data Wizard Pty Ltd

推荐答案

CSV听起来像是一种简单的格式,直到您查看文件中的嵌入式引号,逗号和换行符而忘记了二进制数据.

如果必须走这条路,除非您使用图书馆,否则您要做的工作还很多.

XML文件更加灵活.

语言选择完全取决于您.高级语言更易于操作字符串,而我个人的选择是c#.
CSV sounds like an easy format, until you look at embedded quotes and commas and line feeds in the file and forget about binary data.

If you must go down this road, you have quite a bit of work to do it right, unless you use a library.

XML files are MUCH more flexible.

Language choice is totally up to you. Higher level languages are easier to manipulate strings, and my personal choice is c#.


实际上,我一直在使用datamystic中的textpipe来整理数据.剩下的就是我在这里发布的内容.就整理格式而言,textpipe做得非常漂亮.请指出我要使用C时需要看的内容.谢谢.

Rgrds,
Sheila.
Actually i have been using textpipe from datamystic to sort the data out. What is left is just what i have posted here. As far as sorting out the format, textpipe has done beautifully. Do point me what i need to look at if i want to use C. Thank you.

Rgrds,
Sheila.


尝试查看Awk或Microsoft的LogParser.不确定您的文件格式是什么.如果它们确实是日志,那么analog.cx也将非常有用.
Try looking at Awk or Microsoft''s LogParser. Not sure what your file format''s are. If they really are logs, analog.cx would also be very useful.


这篇关于数据提取到csv的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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