select a.*,'N' FLAG00,decode(a.BRID00,0,'未对应','已对应') DYBZ00, nvl((select d.ECPDBZ from SF_HZBR00 d where d.YSPBID=a.GHHBID and d.HZXH00= a.YYH000),0) as ECPDBZ, nvl((select d.ECPDBZ from SF_HZBR00 d where d.YSPBID=a.GHHBID and d.HZXH00= a.YYH000 and nvl(d.ECPDBZ,0)<>1),0) as ECPDBZ, (select b.SCKBH0 from BM_CKDY00 b,BM_CKBM00 c where b.DCKBH0=a.GHHZCK and b.SCKBH0=c.CKBH00 and c.ZDZTBZ<>'1' and rownum=1) FZCKBH from vw_yy_bryyxxcx a where (a.YYKSBH='458' and a.YYYSBH='441') and a.YYRQ00=to_char(sysdate, 'YYYYMMDD') and ((a.YYJSSJ>'12:00:00' and to_char(sysdate, 'HH24:MI:SS')>'12:00:00' ) or (a.YYJSSJ<='12:00:00' and to_char(sysdate, 'HH24:MI:SS')<='12:00:00' ) or ( to_char(sysdate, 'HH24:MI:SS')>=a.GHQSSJ and to_char(sysdate, 'HH24:MI:SS')<=a.GHJSSJ ) ) and a.YYZT00 in ('0','1') order by a.YYH000