in reply to Re^2: RegEx - match pattern not followed by literal
in thread RegEx - match pattern not followed by literal

I don't think a negative look ahead will work - .*(?!,v) will still match foo,v since the .* can just suck up the ,v

Tom Melly, tom@tomandlu.co.uk
  • Comment on Re^3: RegEx - match pattern not followed by literal

Replies are listed 'Best First'.
Re^4: RegEx - match pattern not followed by literal
by johngg (Canon) on Oct 12, 2006 at 15:47 UTC
    Yes, perhaps that needs to be non-greedy like (?!.*?,v$) but note that the .*? is inside the assertion.

    Cheers,

    JohnGG