本文介绍了是否可以在不打开CSV文件的情况下获取行数?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个〜1 GB的CSV文件,并且由于我的笔记本电脑具有基本配置,因此无法在Excel或R中打开该文件.但是出于好奇,我想获取文件中的行.如果可以的话,我该怎么做?
I have a CSV file of size ~1 GB, and as my laptop is of basic configuration, I'm not able to open the file in Excel or R. But out of curiosity, I would like to get the number of rows in the file. How am I to do it, if at all I can do it?
推荐答案
对于Linux/Unix:
For Linux/Unix:
wc -l filename
对于Windows:
find /c /v "A String that is extremely unlikely to occur" filename
这篇关于是否可以在不打开CSV文件的情况下获取行数?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!