Hi @haixin wang ,
Welcome to our forum!
I found the SQL code works in outlook email.
In order to verify, do you mean you have cteate a new search filter view by adding query in Outlook View tab > View Settings > Filter > SQL tab?
In this case, you can also add other verbs by using operators such as AND, NOT OR, please refer to the link below:
Beside, according to my search, you can create a Search Folder and use the Query Builder tab to construct your query.
To enable the Query Builder, you need to create the following Registry key.
Path: HKEY_CURRENT_USER\Software\Microsoft\Office\16.0\Outlook\
Choose: Edit > New Key
Key: QueryBuilder
More information about Query Builder in this link for your reference: https://www.msoutlook.info/question/276
(Note: Since the web site is not hosted by Microsoft, the link may change without notice. Microsoft does not guarantee the accuracy of this information.)