問題文
A WHERE clause reads job_id = 'SA_REP' OR job_id = 'AD_VP' AND salary > 15000 and the writer expected both job codes to be filtered by the salary. Which rows does the clause actually keep?
選択肢
- It keeps the sales representatives above 15000, together with every vice president regardless of salary, because disjunction binds more tightly than conjunction.
- It keeps the rows of both job codes that are above 15000, because the database reads the three conditions from left to right, applying each one in turn.
- It keeps the rows of both job codes, and it ignores the salary condition, because a condition that follows a disjunction is read as a comment.
- It keeps every sales representative regardless of salary, together with the vice presidents above 15000, because conjunction is evaluated before disjunction.