[Nottingham] Stripping lines out of a text file

JJSH stellafan at jjsh.org
Thu Mar 13 16:04:55 GMT 2008


I've got a bunch of flat files here from an acient database that I need 
to tidy up so that I can import them into MySQL. The first thing I need 
to do is get rid of all the junk data that I don't need. All of the 
needed data is contained on lines that begin with one of the following;

"Size", "EDM", "Material", "Date", "Client".

Can anyone think of a way I can strip out all of the lines that don't 
begin with one of the above, other than tediously going through it 
manually (some of the files are huge)? The remaining data needs to be 
kept in sequence.


TIA

John



More information about the Nottingham mailing list