select A.uid,count(*) from A GROUP by A.uid UNION all
select A.uid,count(*) from A,B where B.neid = A.neid GROUP by A.uid UNION all
select A.uid,count(*) from A,C where C.Type = 'student' and C.neid=A.neid GROUP by A.uid;
如果用每行语句单独查询,结果分别是这样的
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
人生最曼妙的风景,竟是内心的淡定与从容!