1. 忽略大小写

(?i)
^[(?i)(select|SELECT)].*?(?=from)

2. 匹配第一次出现的字符

.*?(?=from)
^[(?i)(select|SELECT)].*?(?=from)

 

相关文章: