I scanning a log file.
The log file has a line that has a phrase such as "Discarded duplicate request message with switch key" which I will call X.
After this line there are many lines containing more details about what was logged with regard to X.
These number of lines can vary.
A new line/event that was logged will typically start with "8/23/2013". I will call this Y.
Now, I want to delete everything from X to the line just before Y. Y must not be deleted.
Then it must carry on searching for the above pattern.
How do I do this using Search and replace?