Using apache pig and the text
hahahah. my brother just didnt do anything wrong. He cheated on a test? no way!
I m trying to match "my brother just didnt do anything wrong."
Ideally, I d want to match anything beginning with "my brother just" and end with either punctuation(end of sentence) or EOL.
Looking at the pig docs, and then following the link to java.util.regex.Pattern, I figure I should be able to use
extrctd = FOREACH fltr GENERATE FLATTEN(EXTRACT(txt, (my brother just .*\p{Punct}) )) as (txt:chararray);
But that seems to match until the end of the line. Any suggestions for performing this match? I m ready to pull my hair out, and by pull my hair out, I mean switch to python streaming