Assume I have a table t1
and two queries q1 and q2 on t1
:
SELECT xxx FROM t1 WHERE <condition-1>
and
SELECT xxx FROM t1 WHERE <condition-2>,
where <condition-1>
logically implies <condition-2>
(i.e., <condition-1>
is stricter than <condition-2>
, and the result set of q1 is a subset of that of q2)
Question:
Will the response time of q1 commonly (if ignore extreme cases) be shorter than that of q2?
This question may seem weird, the reason why I ask is I want to figure out some test oracle for the performance test. If the answer to the above question is true, that may serve as a test oracle.