Mysql Multiple Choice Questions

  1. Which statement is used to change database?
    1. USE db_name;
    2. WANT db_name;
    3. CHANGE db_name;
    4. None of the above
Answer :
A
Explanation:
Added By : Sumit


  1. Which statement is used to find out what databases currently exist on the server?
    1. SHOW DATABASE
    2. SHOW DATABASES
    3. SHOW ALL DATABASES
    4. All the above
Answer :
B
Explanation:
Added By : Sumit

  1. Which command returns current version on MySQL?
    1. SELECT MySQLVERSION();
    2. SELECT VERSION("MySQL");
    3. SELECT VERSION();
    4. All the above
Answer :
C
Explanation:
Added By : Sumit


  1. Which statement is used to connect with mysql server?
    1. mysql -h host_name -u user_name -p password
    2. mysql -u user_name -p password -h host_name
    3. mysql -p password -u user_name -h host_name
    4. All the above
Answer :
D
Explanation:
Added By : Sumit

  1. What is IGNORE keyword in MySQL?
    1. Ignores Primary key or Unique key violations and continues processing with the next row
    2. Ignores Primary key or Unique key violations and leaves any remaining rows unprocessed.
    3. Do not ignores Primary key or Unique key violations
    4. None of the above
Answer :
A
Explanation:
Added By : Sumit

  1. Which is not a valid comment style in MySQL?
    1. # comment
    2. /* comment */
    3. -- comment
    4. //
Answer :
D
Explanation:
Added By : Sumit


  1. What will be the output of this query UPDATE tab_name SET col1 = col1 + 1, col2 = col1;
    1. col1 and col2 have different value
    2. col1 and col2 have same value
    3. col2 has original value of col1
    4. None of the above
Answer :
B
Explanation:
Added By : Sumit

  1. Which is right statement to kill process/thread in MySQL?
    1. KILL ALL thread_id/process_id
    2. KILL thread_id/process_id
    3. REMOVE thread_id/process_id
    4. None of the above
Answer :
B
Explanation:
Added By : Deeksha

Post Your Question
Social Sharing
Search