I am trying to write a replacement regular expression to surround all words in quotes except the words AND, OR and NOT.
I have tried the following for the match part of the expression:
(?i)(?<word>[a-z0-9]+)(?<!and|not|or)
and
(?i)(?<word>[a-z0-9]+)(?!and|not|or)
but neither work. The replacement expression is simple and currently surrounds all words.
"${word}"
So
This and This not That
becomes
"This" and "This" not "That"