SQL中“in”关键字组成的条件格式;它组成的条件表达式的含义
发布网友
发布时间:2022-04-09 20:19
我来回答
共1个回答
热心网友
时间:2022-04-09 21:48
in 关键字组成的 条件格式,类似与or ,如下sql所示
select * from [表名] where [列名] in ('a','b','c')
/*等价于以下sql脚本*/
select * from [表名] where [列名] ='a'
union all
select * from [表名] where [列名] ='b'
union all
select * from [表名] where [列名] ='c'