Mysql Multiple Choice Questions

  1. TCL is used for _______?
    1. Manage the changes made by DML statements
    2. Defining database schema
    3. Control access to data stored in a database
    4. None of the above
Answer :
A
Explanation:
Transaction Control Language (TCL) statements are used to manage the changes made by DML statements. It allows statements to be grouped together into logical transactions. eg. COMMIT, ROLLBACK, SAVEPOINT.
Added By : Amitosh


  1. DCL is used to _______?
    1. Manage the changes made by DML statements
    2. Inserting, Deleting and Updating data
    3. Control access to data stored in a database
    4. None of the above
Answer :
C
Explanation:
A Data Control Language (DCL) is used to control access to data stored in a database. eg. GRANT, REVOKE
Added By : Amitosh

  1. DDL is used for _______?
    1. Manage the changes made by DML statements
    2. Defining database schema
    3. Control access to data stored in a database
    4. None of the above
Answer :
B
Explanation:
A Data Definition Language or Data Description Language (DDL) is used for defining data structures, especially database schemas. eg. CREATE, DROP, ALTER, TRUNCATE
Added By : Amitosh


  1. DML is used for _______?
    1. Control access to data stored in a database
    2. Defining database schema
    3. Inserting, Deleting and Updating data
    4. None of the above
Answer :
C
Explanation:
A Data Manipulation Language (DML) is used for inserting, deleting and updating data in a database. eg. SELECT, INSERT, UPDATE, DELETE.
Added By : Amitosh

  1. Which is right statement to insert multiple records?
    1. INSERT INTO job_question VALUES ('col1', 'col2'), ('col1', 'col2'), ...
    2. INSERT INTO job_question VALUES ('col1', 'col2'), VALUES ('col1', 'col2'), ...
    3. A and B Both
    4. None of the above
Answer :
A
Explanation:
Added By : Akash

  1. Query result can be displayed vertically by terminating the query____?
    1. With \V instead of a semicolon
    2. With \G instead of a semicolon
    3. With \M instead of a semicolon
    4. All the above
Answer :
B
Explanation:
Added By : Deeksha


  1. Which command is used to import data form text file in MySQL on MySQL editor?
    1. mysql> source text_file_path;
    2. mysql> \. text_file_path
    3. None of the above
    4. A and B Both
Answer :
D
Explanation:
Added By : Deeksha

  1. Which is right statement to import data from text file in MySQL on shell editor?
    1. shell> mysql -host host_name -u user_name -p password db_name < text_file
    2. shell> mysql -host host_name -u user_name -p password db_name > text_file
    3. shell> mysql < text_file
    4. All the above
Answer :
A
Explanation:
Added By : Deeksha

Post Your Question
Social Sharing
Search