select count(*)
from change_record cr
where 1 = 1
and cr.change_status_id = 29
and cr.testers = 'yhl'
and (case cr.change_record_res_id when 1 then
(select bug.bug_status_id
from bug_record bug
where bug.bug_id = cr.origin_source_id) when 2 then
(select req.req_status_id
from requirement_record req
where req.req_id = cr.origin_source_id) else 0 end) in (4, 24)
sql: where 中 case
最新推荐文章于 2021-08-17 15:11:45 发布