Search notes:

Oracle SQL Plan operation HASH JOIN FULL OUTER

create table tq84_foj_a (
  id_a   number,
  txt_a  varchar2(10)
);
 
create table tq84_foj_b (
  id_b   number,
  txt_b  varchar2(10)
);
 
begin
  insert into tq84_foj_a values (1, 'abc');
  insert into tq84_foj_a values (2, 'def');
  insert into tq84_foj_a values (3, 'ghi');
 
  insert into tq84_foj_b values (2, 'FOO');
  insert into tq84_foj_b values (4, 'BAR');
end;
/
 
explain plan for
select
  coalesce(a.id_a, b.id_b) id,
  a.txt_a,
  b.txt_b
from
  tq84_foj_a a full outer join
  tq84_foj_b b                   on id_a = id_b;
 
select * from table(dbms_xplan.display(format=>'basic'));
--
-- --------------------------------------------
-- | Id  | Operation             | Name       |
-- --------------------------------------------
-- |   0 | SELECT STATEMENT      |            |
-- |   1 |  VIEW                 | VW_FOJ_0   |
-- |   2 |   HASH JOIN FULL OUTER|            |
-- |   3 |    TABLE ACCESS FULL  | TQ84_FOJ_B |
-- |   4 |    TABLE ACCESS FULL  | TQ84_FOJ_A |
-- --------------------------------------------
 
drop table tq84_foj_a purge;
drop table tq84_foj_b purge;

See also

Plan operations

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/developm...', 1758199276, '216.73.216.150', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/development/databases/Oracle/SQL/statement/execution/plan/operations/hash-join/outer/full(77): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78