select XXX as XXX from XX where id=%d
try this
'^select\b[^\b]+\bas\b[^\b]+\bfrom\b[^\b]+\bwhere\b[^\b]+\b=[0-9]+\b$'
select * from 表名 where 表下的某个项名 = 'xxx';xxx是你要搜索的关键词