select count(t.tel)as a
,(select 1 from dual)as b
from mms.tb_mmslist t
group by t.Dataid

解决方案 »

  1.   

    简单表示就是:
    select count(f1) as a,
    (select 1 from dual) as b
    from tb
    group by f2提示:不是group by表达式
    光标在第二行
      

  2.   

    在ms-sqlserver中是没有问题的,ORACLE不支持?
      

  3.   

    try:
    select count(f1) as a,1 as b from tb group by f2
      

  4.   

    谢谢!
    select 1 from dual只是个例子,实际用的时候要加WHERE条件的
    麻烦再看看
      

  5.   

    select * from 
    (select count(f1) as a
    from tb
    group by f2) aa,
    (select col... from dual) as b
    where aa.col=b.col...;