select a.*,
isnull(b.c,0) as list1记录数,
isnull(c.c,0) as list1记录数
from info_sort a left join
( select sort,count(*) as c
from info_list1
group by sort
) b on a.id=b.sort
left join
( select sort,count(*) as c
from info_list2
group by sort
) c on a.id=c.sort
select a.id,a.name,
记录数1=(select count(*) from info_list1 b where a.id=b.sort),
记录数2=(select count(*) from info_list2 c where a.id=c.sort)
from info_Sort a