mysql 有没有类似SQL SERVER的IN的功能的呢?怎么实现啊

niuniu 2004-11-20 11:13:57
mysql 有没有类似SQL SERVER的IN的功能的呢?怎么实现啊
...全文
139 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
mathematician 2004-12-08
  • 打赏
  • 举报
回复
4.1以上版本支持IN,update的in子查询也是可以的。

update table set A='B' where id in (select id form table2 where b='a');
bruni 2004-12-07
  • 打赏
  • 举报
回复
mysql4.1支持子查询了
ghostboy1020 2004-11-22
  • 打赏
  • 举报
回复
我知道支持select * from table where id in(select id form table2 where b='a')
不支持update table set A='B' where id in(select id form table2 where b='a')
DeltaCat 2004-11-21
  • 打赏
  • 举报
回复
可以啊
select * from [table] where id in (1,2,3,4)

如果是嵌套查询的话, MYSQL 4.1以下的版本不支持
ghostboy1020 2004-11-21
  • 打赏
  • 举报
回复
我也是这个问题啊,你解决了能给我http://community.csdn.net/Expert/TopicView1.asp?id=3571960也回复下吗??

56,679

社区成员

发帖
与我相关
我的任务
社区描述
MySQL相关内容讨论专区
社区管理员
  • MySQL
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧