MySQL Database Multiple Choice Questions on “Basic Database Terminology”.
1. Which type of database management system is MySQL?
a) Object-oriented
b) Hierarchical
c) Relational
d) Network
Answer: c
Clarification: MySQL is a ‘relational’ DBMS. It is efficient at relating data in two different tables and joining information from them. Hierarchical and Network DBMS are based on parent-child relationships of records. Object-oriented DBMS use objects to represent models.
2. What is data in a MySQL database organized into?
a) Objects
b) Tables
c) Networks
d) File systems
Answer: b
Clarification: Since MySQL is an RDBMS, it’s data is organised in tables for establishing relationships. A table is a collection of rows and columns, where each row is a record and columns describe the feature of records.
3. MySQL is freely available and is open source.
a) True
b) False
Answer: a
Clarification: MySQL is free and open source. It’s source code is available for use and is freely downloadable. It includes the MySQL Server, the world’s most popular open source database, and MySQL Cluster, a real-time, open source transactional database.
4. What represents an ‘attribute’ in a relational database?
a) Table
b) Row
c) Column
d) Object
Answer: c
Clarification: Each column in a table represents a feature (attribute) of a record. Table stores the information for an entity whereas a row represents a record. Object has no relevance in an RDBMS.
5. What represents a ‘tuple’ in a relational database?
a) Table
b) Row
c) Column
d) Object
Answer: b
Clarification: Each row in a table represents a record. A tuple is a collection of attribute values that makes a record unique. A tuple is a unique entity whereas attribute values can be duplicate in the table.
6. How is communication established with MySQL?
a) SQL
b) Network calls
c) A programming language like C++
d) APIs
Answer: a
Clarification: SQL is the standard language for RDBMS systems like MySQL. SQL queries facilitate quick information retrieval from tables and other elementary operations required to maintain an RDBMS system.
7. What does ‘name’ represent in the following SQL code snippet?
CREATE TABLE student ( name CHAR(30), roll_num INT, address CHAR(30), phone CHAR(12) );
a) A table
b) A row
c) A column
d) An object
Answer: c
Clarification: ‘name’, ‘roll_num’, ‘address’ and ‘phone’ are the attributes in the table ‘student’. The CREATE TABLE construct in SQL creates a table, assigns a name to it and its attributes, and specifies the type of fields used in the table.
8. Which is the MySQL instance responsible for data processing?
a) MySQL client
b) MySQL server
c) SQL
d) Server daemon program
Answer: b
Clarification: MySQL uses client-server architecture. The MySQL server program runs on the machine where databases are stored. SQL is a query language used for querying the tables and information retrieval.
9. The MySQL server used in its client/server architecture is _______________
a) mysqla
b) mysqlb
c) mysqlc
d) mysqld
Answer: d
Clarification: mysqld is the MySQL server program. It serves the incoming client requests by accessing the database. The others are not valid MySQL programs. MySQL implements a client/server architecture wherein mysqld is the server program.
10. In MySQL databases, the structure representing the organizational views of the entire databases is ____________
a) Schema
b) View
c) Instance
d) Table
Answer: a
Clarification: The schema in a database gives a blueprint of the structure. A view is an object that can be generated with a query. A table is a collection of records. An instance is analogous to a class object.
