sql server 在sql語句裏面的where 後面的判斷

sql :  where  1=1 and      and name = case when (SUBSTRING(Type,3,1)='J') then '張三' else '李四' end  解釋:Type截取第三位,若是是J,名字就是張三,若是不是,名字就是李四sql
相關文章
相關標籤/搜索