select t.bb_id as bbid,
t.bb_mc as bbmc,
(select count(*)
from bb_depend_relation b
where b.depend_bb_no = t.bb_id
and b.bb_no = '2c90387914905e77011490b5cc16001a') as bj,
(select DEPEND_RANGE
from bb_depend_relation b
where b.depend_bb_no = t.bb_id
and b.bb_no = '2c90387914905e77011490b5cc16001a') as ylfw,
(select DEPEND_PHASE
from bb_depend_relation b
where b.depend_bb_no = t.bb_id
and b.bb_no = '2c90387914905e77011490b5cc16001a') as yljd
from bb_xx t
-->>
select t.bb_id as bbid,
t.bb_mc as bbmc,
count(*) as bj,
DEPEND_RANGE as ylfw,
DEPEND_PHASE as yljd
from bb_xx t join bb_depend_relation b on b.depend_bb_no = t.bb_id and b.bb_no = '2c90387914905e77011490b5cc16001a'
t.bb_mc as bbmc,
(select count(*)
from bb_depend_relation b
where b.depend_bb_no = t.bb_id
and b.bb_no = '2c90387914905e77011490b5cc16001a') as bj,
(select DEPEND_RANGE
from bb_depend_relation b
where b.depend_bb_no = t.bb_id
and b.bb_no = '2c90387914905e77011490b5cc16001a') as ylfw,
(select DEPEND_PHASE
from bb_depend_relation b
where b.depend_bb_no = t.bb_id
and b.bb_no = '2c90387914905e77011490b5cc16001a') as yljd
from bb_xx t
-->>
select t.bb_id as bbid,
t.bb_mc as bbmc,
count(*) as bj,
DEPEND_RANGE as ylfw,
DEPEND_PHASE as yljd
from bb_xx t join bb_depend_relation b on b.depend_bb_no = t.bb_id and b.bb_no = '2c90387914905e77011490b5cc16001a'
select t.bb_id as bbid,
t.bb_mc as bbmc,
count(*) as bj,
DEPEND_RANGE as ylfw,
DEPEND_PHASE as yljd
from bb_xx t join bb_depend_relation b on b.depend_bb_no = t.bb_id and b.bb_no = '2c90387914905e77011490b5cc16001a'
group by t.bb_id,t.bb_mo,DEPEND_RANGE ,DEPEND_PHASE