|
-
Jun 18th, 2003, 10:44 AM
#1
Thread Starter
Fanatic Member
Regular Expression Question
I want to match insert statements that have a select clause instead of a values clause. (i.e. "insert into... select * from ..." but not "insert into ... values(...)"
I use the following regular expression:
\binsert\b(?:.|\n)+?(?!values)\bselect\b
I thought that the (?!values) would tell the parser to stop if it hit the string "values", but perhaps I do not fully understand negative lookaheads...
Is there any way I can accomplish my goal?
BTW, disable smilies unless you want some weird looking regular expressions ;)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|