SQL Server 中查询以某字母开头的数据
查询字段中以B开头的数据。
select from Table where left(字段名,1) = 'B'
或者
select * from a where a.name REGEXP ''^(B|S)'';
参考: 就是你baby@
查询非空数据
select * from table where 字段名 is null
查询字段中以B开头的数据。
select from Table where left(字段名,1) = 'B'
或者
select * from a where a.name REGEXP ''^(B|S)'';
参考: 就是你baby@
查询非空数据
select * from table where 字段名 is null