Home » MYSQL » Mysql miscellaneous » Question
  1. What will be the output of the following query?
    SELECT accountid, productid, custid
    FROM account
    WHERE productid NOT IN (‘sav’, ‘chd’, ‘mm’);
    1. Only those values are selected whose productid does not belong to either ‘sav’’
    2. Only those values are selected whose productid does not belong to either ‘sav’, ‘chd’
    3. Only those values are selected whose productid does not belong to either ‘sav’, ‘chd’, ‘mm’
    4. All of above
    5. None of these
Correct Option: C

“NOT IN” worked opposite of “IN” operator.



Your comments will be displayed only after manual approval.