'LIKE ('%this%' OR '%that%') and something=else' not working

前端 未结 7 1389
南方客
南方客 2020-12-15 14:53

I have a select query where I am trying to search strings for multiple patterns

LIKE (\'%this%\' or \'%that%\' ) and something=else

Returns

7条回答
  •  轻奢々
    轻奢々 (楼主)
    2020-12-15 15:51

    Do you have something against splitting it up?

    ...FROM  
       WHERE 
         (fieldA LIKE '%THIS%' OR fieldA LIKE '%THAT%') 
         AND something = else
    

提交回复
热议问题