This week's book giveaway is in the JavaScript forum.
We're giving away four copies of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js and have Paul Jensen on-line!
See this thread for details.
Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Need a script to handle big files  RSS feed

 
M Burke
Ranch Hand
Posts: 410
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a file that has 2 million rows (Database import). Its part of a batch process and is refreshed once a month. I would like to break it up into 100K row chunks. Anyone know of a script that does this? Thanks
 
Stefan Wagner
Ranch Hand
Posts: 1923
Linux Postgres Database Scala
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

will generate files called PREFIXaa, PREFIXab, PREFIXac ... of 100000 lines each.
 
Jay Suttiruttana
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Continue from Stefan post.

The "split" is a tool available in UNIX and Linux OS environment. If you're in MS Windows environment, there is a GUI tool called JR Split File (http://www.spadixbd.com/freetools/index.htm).
 
M Burke
Ranch Hand
Posts: 410
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Cool, thanks guys
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!