특정 조건을 기준
으로 원하는 행을 출력연산자를 함께 사용
하여 세밀하게 데이터 검색SELECT LAST_NAME , SALARY FROM EMPLOYEES e WHERE SALARY = 12000 ;
-- AND : A 이고 B 인 값 SELECT DEPARTMENT_ID , SALARY FROM EMPLOYEES e WHERE DEPARTMENT_ID = 30 AND SALARY >= 3000 ;
-- OR : A 이거나 B 인 값 SELECT DEPARTMENT_ID , SALARY FROM EMPLOYEES e WHERE DEPARTMENT_ID = 30 OR SALARY >= 3000 ;
SELECT DEPARTMENT_ID , SALARY FROM EMPLOYEES e WHERE DEPARTMENT_ID IN (30, 40, 50, 60) AND SALARY IN (6500, 7700, 13000);
SELECT DEPARTMENT_ID , FIRST_NAME FROM EMPLOYEES e WHERE DEPARTMENT_ID IN (30, 40, 50, 60) AND (FIRST_NAME LIKE '%a%' OR FIRST_NAME LIKE '%b%') ;
-- MANAGER_ID 가 100이 아니거나, 102가 아니거나, 108이 아닌 값
SELECT MANAGER_ID
FROM EMPLOYEES e
WHERE MANAGER_ID NOT IN (100, 102, 108)
;