Search notes:
Oracle SQL: Execution plan for UPDATE stement with a FROM clause
drop table if exists tq84_dst;
drop table if exists tq84_src;
create table tq84_dst (
id integer,
val number
);
create table tq84_src (
id integer,
val_new number
);
explain plan for
update
tq84_dst dst
set
dst.val = src.val_new
from
tq84_src src
where
dst.id = src.id;
select * from table(dbms_xplan.display(format=>'basic'));
--
-- ----------------------------------------
-- | Id | Operation | Name |
-- ----------------------------------------
-- | 0 | UPDATE STATEMENT | |
-- | 1 | UPDATE | TQ84_DST |
-- | 2 | HASH JOIN | |
-- | 3 | TABLE ACCESS FULL| TQ84_SRC |
-- | 4 | TABLE ACCESS FULL| TQ84_DST |
-- ----------------------------------------