select va.irid ov_irid, va.to_ivid ov_ivid
      from SDD_VERSION_ASSOCIATIONS va
          ,I$SDD_DEU deu
          ,I$SDD_BRANCHES br
     where deu.parent_ivid in (select jr_name.get_IVID(:diagram) from sys.dual)
     and va.irid = deu.cielement_ref
     and va.edge_kind = ('T')
     and va.branch_id = br.branch_id
     and br.name=:branch