9i+ case b.f_sitelink when 9  then '结束' else c.f_sitename end 一样可以用
8i中 decode(b.f_sitelink,9,'结束',c.f_sitename)

解决方案 »

  1.   

    使用函数
    DECODE( expr, search, result [, search, result] ... [, default] )     To evaluate this expression, Oracle compares expr to each search 
        value one by one.  If expr is equal to a search, Oracle returns the 
        corresponding result.  If no match is found, Oracle returns default, 
        or, if default is omitted, returns null.  If expr and search contain     character data, Oracle compares them using non-padded comparison 
        semantics.