inline view
-
day08 - 오라클 (다중 컬럼, scalar sub query, inline view, exists 와 not exists)KIC/DB 오라클 2021. 7. 10. 23:17
[다중 컬럼] select empno, name, birthday, pay, position from emp2 where (pay, position) in (select max(pay), position from emp2 group by position); select empno, name, birthday, pay, position from emp2 where pay = (select max(pay) from emp2 where position = e.position); [scalar sub query(스칼라 서브쿼리)] -> select 문에서 서브쿼리 추가 --emp2 의 deptno 와 dept2의 dcode 숫자 형식이 일치 select * from emp2; select * from dept2..