undefinedfix
Sign in

Regular expression: does not match string beginning with XXX

Smit edited in Thu, 24 Nov 2022

I have two SQL statements. Statement a: select * from table1; statement B: select * from XXX.TABLE1 Now I want to use the regular expression to extract the table name table1 without the prefix XXX? According to the official document, it should be (?! \.) table1, but it doesn't seem to match. thx

2 Replies
COMTOP
commented on Fri, 25 Nov 2022

Click to view the matching results

Regular as follows: (? <! XXX \.) table1 in Java code, to write: (? <! XXX \ \.) table1

Gum
commented on Fri, 25 Nov 2022

(?<!XXX.)TABLE1

image.png