悬赏园豆:10
[已关闭问题]
<P>我写了个这样的T_SQL语句</P>
<P>select sid,subject,content,pubdate,promulgator=<BR> case<BR> when exists(select * from snm_scheme where did>0) then (select name from snm_department where snm_department.did=snm_scheme.did and snm_scheme.did>0) <BR> when exists(select * from snm_scheme where cid>0) then (select name from snm_Center where snm_center.cid=snm_scheme.cid and snm_scheme.cid>0) <BR> else <BR> (select username from snm_user where snm_user.uid=snm_scheme.uid)<BR> end </P>
<P>from snm_scheme</P>
<P>我想给promulgator字段筛选后都有数据填充.现在的问题是 获得的promulgator 列结果中只有满足第一个when 条件的数据填充,这是怎么回事啊?</P>
<P>有没有办法能解决</P>