|
|
| We don't bite newbies here... much | |
| PerlMonks |
Comment on |
| ( #3333=superdoc: print w/ replies, xml ) | Need Help?? |
|
I have a file of about 1B records, each containing 50 tab-separated fields. I'm writing a small app to pass this file on an ad-hoc basis, selecting and concatenating various of these fields. For example: if the input file contains FIRST\tMIDDLE\tLAST\tSTRNO\tSTRNAME\tCITY\tSTATE\tZIP\t...\n I might wish to extract fields 3, 1, and 6: LAST\tFIRST\tCITY\nMy current approach begins by splitting each record into a 50-element array and then accessing each by index. It's very slow. Can someone suggest a superfast approach to doing this, given only the set of indices I wish to extract? In reply to selecting columns from a tab-separated-values file by ibm1620
|
|