记录为空时怎么返回默认的一条记录

dongni110 2009-03-20
如:
    select a,b,c from table 结果集为空记录.
    a b c
怎么让它返回一条默认的记录,如
    a b c
  0 0 0
lndalian2000 2009-04-10
NVL应该就可以。
wmdonald 2009-04-12
select nvl(a,0),nvl(b,0),nvl(c,0) from table;
jayzotion 2009-05-13
select  0 as a,0 as b,0 as c from tableName where not exists(select 1 from tableName)
fycghy0803 2009-07-13
select 0 as a,0 as b ,0 as c from(select count(*) as a,0 as b,0 as c from table_name) cc where cc.a = 1;
Rowen 2009-07-13
引用
select nvl(a,0),nvl(b,0),nvl(c,0) from table;

nvl up
Global site tag (gtag.js) - Google Analytics