WITH 검색대상테이블 AS ( SELECT 1 번호, '홍길동' 이름 FROM dual UNION ALL SELECT 2, '일지매' FROM dual UNION ALL SELECT 3, '심봉사' FROM dual ) , 검색조건테이블 AS ( SELECT 1 번호 FROM dual UNION ALL SELECT 3 FROM dual UNION ALL SELECT 4 FROM dual UNION ALL SELECT 2 FROM dual ) SELECT a.번호 , NVL(b.이름, '없음') 이름 FROM 검색조건테이블 a , 검색대상테이블 b WHERE a.번호 = b.번호(+) ;