Home / CSE MCQs / MySQL Database MCQs :: MySQL Database Select Statement

CSE MCQs :: MySQL Database MCQs

  1. What is the meaning of "Temporary Tables in Mysql?
  2. A.
    Rows returned by sub query
    B.
    Permanent tables
    C.
    Virtual tables
    D.
    All of the mentioned

  3. What will be the output of the following statement "false AND Null?
  4. A.
    false
    B.
    Null
    C.
    Depend
    D.
    None of the mentioned

  5. "COUNT keyword belongs to which categories in Mysql?
  6. A.
    Aggregate functions
    B.
    Operators
    C.
    Clauses
    D.
    All of the mentioned

  7. Which clause is used with an "aggregate functions?
  8. A.
    GROUP BY
    B.
    SELECT
    C.
    WHERE
    D.
    Both a and c

  9. If emp_id contain the following set {-1, -2, 2, 3, -3, 1}, what will be the output on execution of the given query?

    SELECT emp_id
    FROM person
    ORDER BY emp_id;
  10. A.
    {-3, -2, -1, 1, 2, 3}
    B.
    {-1, 1, -2, 2, -3, 3}
    C.
    {1, 2, 3, -1, -2, -3}
    D.
    None of the mentioned

  11. If emp_id contain the following set {9, 7, 6, 4, 3, 1, 2}, what will be the output on execution of the given query?

    SELECT emp_id
    FROM person
    ORDER BY emp_id DESC;
  12. A.
    {9, 7, 6, 4, 3, 1, 2}
    B.
    {1, 2, 3, 4, 6, 7 , 9}
    C.
    {2, 1, 3, 4, 6, 7, 9}
    D.
    None of the mentioned

  13. Is there any error in the following query?

    SELECT emp_id, title, start_date, fname, fed_id
    FROM person
    ORDER BY RIGHT (fed_id, 3);
  14. A.
    Yes
    B.
    No error
    C.
    Depends
    D.
    None of the mentioned

  15. What will be the output of a query given below?

    SELECT person_id, Fname, lname
    FROM person;
  16. A.
    Show only columns (person_id, Fname, lname) and rows related to these columns
    B.
    Show only columns (person_id, Fname, lname)
    C.
    Show all rows
    D.
    Show all columns except (person_id, Fname, lname)

  17. What will be the result of the query given below?

    SELECT emp_id,
    'ACTIVE' AS STATUS,
    emp_id * 3.14 AS emp_pi,
    UPPER (lname) AS last_name
    FROM employee;
  18. A.
    emp_id, ACTIVE, emp_id * 314, UPPER(lname)
    B.
    emp_id, Status, emp_pi, last_name
    C.
    Error
    D.
    None of the mentioned