Can someone tell me why this is allowed:
but this is not allowed and can I do this below without using MERGE or CURSORs?
Code:
update
(select su.sec_usr_id,su.is_enbl_ind,t.asn_usr_id,t.stat_typ_cd,su.lst_updt_dt
from sec_usr su, tsk t
where su.is_enbl_ind = 0
and su.sec_usr_id = t.asn_usr_id
and t.stat_typ_cd = 'OPEN')u
set u.stat_typ_cd = 'CLOSED';
but this is not allowed and can I do this below without using MERGE or CURSORs?
Code:
update
(select su.sec_usr_id,su.is_enbl_ind,t.asn_usr_id,t.stat_typ_cd,su.lst_updt_dt
from sec_usr su, tsk t
where su.is_enbl_ind = 0
and su.sec_usr_id = t.asn_usr_id
and t.stat_typ_cd = 'OPEN')u
set u.stat_typ_cd = 'CLOSED',
u.lst_updt_dt = sysdate;