I have a single log-type ASCII text file whose lines come in a significant number of possible line formats (perhaps 50?).
I want to test each line to see if it contains one of a number of unique strings, and write the line to an output file if any of these required strings is found.
If the line contains none of the required strings, or contains one of a number of NON-required strings, the line is to be ignored.
The strings would usually contain more than one word separated by blanks, and the line will usually contain at least one email address wrapped in angle brackets (e.g. )
The built-in commands FIND and FINDSTR really only handle a single string, without errors, so up to 50 runs against the same input file would be somewhat inefficient!
Does anyone know of a command-line utility which would do this? (If anyone has a UK IBM mainframe background, what I’m really asking for is a free version of the SELCOPY utility!)
BATcher
Plethora means a lot to me.