use Underline in wild card charecter of Like query gives wrong result

●Question
Why the SQL execution always return the wrong result when i use 'underline' ?
select  * 
from  user
where  userid like 'Karen_Chang%'  

●Solution
Use brackets! []
select  * 
from  user
where  userid like 'Karen[_]Chang%'

沒有留言: