Multiple choice technology databases

Suppose i've a table emp and id is one of the column in it, what will be result for this query.select * from emp where id=99999 and 1=0;

  1. it'll display the result of which id=99999

  2. no rows selected

  3. Error

  4. garbage value...

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

The query contains id=99999 AND 1=0. Since 1=0 is always false, the entire WHERE condition evaluates to false regardless of the id value. SQL will return no rows, not an error. This is a valid query that simply matches no records.