时间:2021-07-01 10:21:17 帮助过:5人阅读
1.标量子查询
select *from myuser where classid=
(
select classid from myclass
where classname=‘2班‘
)
2.列子查询
select *from myuser where classid in
(
select classid from myclass
)
3.行子查询
SELECT * from myuser
where (classid,age)=
(
select max(classid),min(age)
from myuser
)
mysql 子查询
标签:user mysq max ssid mysql name select 子查询 ssi