[Editorial insertion: Possible duplicate of the same poster\'s earlier question?]
Hi, I need to extract from the file:
first second
grep -A1 "second" | grep -B1 "third" works nicely, and if you have multiple matches it will even get rid of the original -- match delimiter