我有以下查询,这是行不通的。
select * from table where id in (
1,2, (select id from another_table)
)
我该如何重写?
怎么样
select * from table
where id in (1,2)
or id in (select id from another_table)
WHERE
使用and
!!!添加其他条件时,请小心并使用括号!
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句