请教in的用法? select * from tablename where charindex(',2,',','+type+',')>0 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 select * from tablename where charindex(',2,',','+type+',')>0 没必要用in,可以以下方法:select * from tablename where type like '%2%'select * from tablename where charindex('2',type)>0 select * from tb1 where charindex(type,'2')=1 select * from tb1 where charindex(name1,'2')=1 select * from tablename where type in ('2','3','4','5') select * from tablename where type like '%2%'select * from tablename where charindex('2',type)>0 求推荐SQL SERVER参考书 请问如何快速建一张大表 sql哪种效率最高 排序问题 ms_SQL服务自动关闭,又自动启动 为何我的存储过程会回滚不执行呀? 如何获得排序后的最前10000条记录的某些字段的和? 为什么SELECT语句的VALUES()可以插入数字不能插入字符? SQL Server2000函数的严重BUG,将导致Sql server服务异常中止 vfp中,dbf表可不可放在内存中使用? 高手门帮我 解决sql server 的 sspi 上下文错误 SQLSERVER存储空间的问题(在线等)
select * from tablename where type like '%2%'
select * from tablename where charindex('2',type)>0
select * from tablename where charindex('2',type)>0