Here is the sample data from a JBehave story that I want to extract from:
And we validate that the following occurrences for event 123456 and source PLAYER are saved in Database:
| PLAYER | GAME |
| 1 | FOOTBALL |
And we validate that the following messages for event 123456 and source PLAYER are sent in Other Database:
Using the fixed phrase:
And we validate that the following occurrences for event 123456 and source PLAYER are saved in Database:
I want to use that sentence as the starting point of my search and get everything up until the next word And
Expected Output:
And we validate that the following occurrences for event 123456 and source PLAYER are saved in Database:
| PLAYER | GAME |
| 1 | FOOTBALL |
I have tried the following expression:
\w*:[^And]*
However, I haven't figured out the part where I match using the fixed phrase.