根据类型返回字段名 如果是0 返回 用户名 如果是 1 返回机构名
select t.rcv_type, decode(t.rcv_type, 0, (select tt.name
from tb_user tt
where t.* ** **
), 1, (select ttt.dept_name
from tb_dept ttt
where t.* ** **
))
from TB_AFFICHE_RECEIVER t
where后面关联条件
select t.rcv_type, decode(t.rcv_type, 0, (select tt.name
from tb_user tt
where t.* ** **
), 1, (select ttt.dept_name
from tb_dept ttt
where t.* ** **
))
from TB_AFFICHE_RECEIVER t
where后面关联条件