I'm trying to export lines 100 to 1,000,100 from a file with 62 million lines. So far I've found this command:
head -1100000 input > output
But head does not take an offset option.
Thoughts?
Combine head
with tail
:
tail -n+100 input | head -n1000000 > output
You can also use sed
:
sed -n '100,1000100p' input > output
sed
' command.
Oct 7, 2012 at 22:37