当前位置: 代码迷 >> Sql Server >> 查询没有某个字母语句?该怎么解决
  详细解决方案

查询没有某个字母语句?该怎么解决

热度:93   发布时间:2016-04-27 19:58:57.0
查询没有某个字母语句?
有张y表
      a
n32
d67
231
t78
b659

在y表里怎么查询a字段这列里有带有b字母的。

------解决方案--------------------

select * from t where a not like '%b% '
------解决方案--------------------
or

select * from t where patindex( '%b% ',a)=0
  相关解决方案