I have a regex that is doing a positive lookahead. The positive lookahead relies on "cfu/ml" being present in the string but doesn not include it in the result.
Here's the regex:
((((less|greater)\s*tha[nt]\s*)?[><]*[\d]+[\sx,.-]*)*)+(?=CFU\s?/\s?ML)
Ex string: "100,000,000 x 85 x 9345 cfu/ml"
Match1: "100,000,000 x 85 x 9345"
That's working just fine, but trying to match anything after that positive lookahead is not working. What I'm trying to do is add another result capture group after the positive look ahead like so.
((((less|greater)\s*tha[nt]\s*)?[><]*[\d]+[\sx,.-]*)*)+(?=CFU\s?/\s?ML)\s*blah
Ex string: "100,000,000 x 85 x 9345 cfu/ml blah"
Match1: "100,000,000 x 85 x 9345"
Match2: "blah"
Seems like nothing after the positive look ahead works, anyone know how I can fix this?