1

Extracting lines by key from very large file

view story
linux-howto

http://unix.stackexchange.com – I have a 42M line text file. Th first nine characters of each line are a numeric key. What is the most efficient way to extract only the lines whose key exists in another list of about 1.5M keys? Both the file and the list of keys are sorted. (HowTos)