select 上网方式,count(上网方式)as 人数 from 
    表2 as t1,表1 as t2 where t1.编号=t2.编号
    group by 上网方式

解决方案 »

  1.   

    select 表2.上网方式,count(a.用户名) from 表1,表2 where 表1.编号=表2.编号 group by 表2.上网方式
      

  2.   

    可以使用sql:
      select 表2.上网方式,count(表1.用户名) from 表1,表2 where 表1.编号=表2.编号 group by 上网方式
      

  3.   

    SELECT 上网方式,COUNT(上网方式) AS 人数
    FROM
    (SELECT 上网方式
            FROM table1 , table2
            WHERE table1.编号 = table2.编号)aa
    GROUP BY 上网方式