This set of MySQL Database Multiple Choice Questions & Answers (MCQs) focuses on “Putting Perl DBI to Work”.
1. RTF refers to ______________
a) Rich Text Format
b) Right Text Format
c) Rich Text Function
d) Right Text Function
View Answer
Explanation: RTF (Rich Text Format) is a format developed by Microsoft that is understood by many word processors. MS-Word is one such program. Many others such as ‘OpenOffice’ understand it too.
2. The function returning an array of row values is ______________
a) fetchrow_array()
b) fetchrow_arrayref()
c) fetch()
d) fetchrow_hashref()
View Answer
Explanation: The function ‘fetchrow_array()’ returns an array of row values. ‘fetchrow_arrayref()’ returns a reference to an array of row values. ‘fetch()’ is the same as fetchrow_arrayref().
3. The function returning reference to hash of row values is ______________
a) fetchrow_array()
b) fetchrow_arrayref()
c) fetch()
d) fetchrow_hashref()
View Answer
Explanation: The function ‘fetchrow_hashref()’ returns reference to hash of row values. ‘fetchrow_arrayref()’ returns a reference to an array of row values. ‘fetch()’ is the same as fetchrow_arrayref().
4. fetchrow_hashref() returns reference to hash of row values keyed by ______________
a) row name
b) column name
c) table name
d) database name
View Answer
Explanation: The function ‘fetchrow_hashref()’ returns reference to hash of row values, keyed by the column name. The function ‘fetchrow_arrayref()’ returns a reference to an array of row values.
5. The function returning reference to array of row values is ______________
a) fetchrow_array()
b) fetchrow_arrayref()
c) fetch()
d) fetchrow_hashref()
View Answer
Explanation: ‘fetchrow_arrayref()’ returns a reference to an array of row values. The function ‘fetchrow_hashref()’ returns reference to hash of row values. ‘fetch()’ is the same as fetchrow_arrayref().
6. What is the maximum non zero value for FLOAT?
a) 3.402823466E+38
b) 3.402823466E+37
c) 3.402823466E+39
d) 3.402823466E+35
View Answer
Explanation: In MySQL, each datatype has its own range. Data types give an idea of the kind of values and the ranges that a variable is allowed to store. The maximum non zero value for FLOAT is 3.402823466E+38.
7. What is the maximum non zero values for DOUBLE?
a) ±1.7976931348623157E+307
b) ±1.7976931348623157E+308
c) ±1.7976931348623157E+306
d) ±1.7976931348623157E+305
View Answer
Explanation: In MySQL, all the datatypes have their own ranges. Data types give an idea of the kind of values and the ranges that a variable is allowed to store. The maximum non zero value for DOUBLE is ±1.7976931348623157E+308.
8. Illegal values converted to the appropriate ‘zero’ value for ______________
a) Numeric
b) String
c) ENUM
d) TIME
View Answer
Explanation: In MySQL, there are different ways to handle the illegal values for different datatypes for default. For date or time columns, illegal values are converted to the appropriate “zero” value for the type.
9. The column attribute provides unique numbers for identification is ______________
a) AUTO_INCREMENT
b) UNSIGNED
c) IDENTIFY
d) DESCRIBE
View Answer
Explanation: In MySQL, the mechanism for providing unique numbers is through the AUTO_INCREMENT column attribute. It enables the generation of sequential numbers automatically. This facilitates identification.
Sanfoundry Global Education & Learning Series – MySQL Database.
To practice all areas of MySQL Database, here is complete set of 1000+ Multiple Choice Questions and Answers.
- Apply for Programming Internship
- Check Information Technology Books
- Practice Programming MCQs
- Check MySQL Books