This set of MySQL Database Multiple Choice Questions & Answers (MCQs) focuses on “Access Control and Security”.
1. MySQL uses security based on ACL which stands for ______________
a) Access Control Language
b) Access Control Lists
c) Automatic Control Lists
d) Automatic Control Language
View Answer
Explanation: MySQL uses security based on Access Control Lists (ACLs) for all connections, queries and other operations that users can attempt to perform. There is support for SSL encrypted connections.
2. The mysql client writes a record of executed statements to a history file on Unix.
a) True
b) False
View Answer
Explanation: On Unix the mysql client writes a record of the executed statements to a history file. By default this file is named as ‘.mysql_history’. It is created in the home directory.
3. A password applies globally to an account.
a) True
b) False
View Answer
Explanation: In the MySQL privilege system, a password applies globally to an account. A password cannot be explicitly associated with a specific object such as a database, table, or routine.
4. The context in which the privilege ‘CREATE TABLESPACE’ applies is ______________
a) Server administration
b) Tables
c) Stored routines
d) Views
View Answer
Explanation: The column name associated with the privilege ‘CREATE TABLESPACE’ is ‘Create_tablespace_priv’. The context in which this privilege is being used is the server administration.
5. The number of languages that have interfaces to bind to the C API of MySQL among these is ______________
Perl, PHP, Python
a) 0
b) 1
c) 2
d) 3
View Answer
Explanation: The client library provides the means through which the MySQL bindings for other languages can be built on top of the C API. This type of interface exists for Perl, PHP, Python and others.
6. The language that is the core for APIs and communication in MySQL is ______________
a) C
b) C++
c) Python
d) Ruby
View Answer
Explanation: In order to provide application development, MySQL provides a client library written in the C programming language. It enables access to MySQL databases from a C program.
7. The most general purpose language is ______________
a) C
b) Perl
c) Python
d) PHP
View Answer
Explanation: C is a general purpose language, so in principle, it can be used for anything. C tends to be used more often for standalone programs rather than for Web programming in practice.
8. The language in which image processing is least simple is ______________
a) PHP
b) Perl
c) Python
d) C
View Answer
Explanation: It is not as easy to perform text processing and memory management in C than it is in languages like Perl and PHP. These capabilities tend to be heavily used in web applications.
9. The option necessary to compile a C program havin math functions is ______________
a) -lm
b) -ln
c) -lp
d) -lq
View Answer
Explanation: To compile a program written in the C language, it is compiled by issuing the option ‘-lm’. The examples of some math functions found in ‘math.h’ are floor(), sqrt(), pow(), log().
10. What is the option for specifying the executable name while compiling with gcc?
a) -e
b) -o
c) -a
d) -b
View Answer
Explanation: When a C program is compiled with gcc, the option -o is issued in order to specify the name of the executable that is created after compilation. The default name given is ‘a.out’.
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.
- Check Information Technology Books
- Check MySQL Books
- Practice Programming MCQs
- Apply for Programming Internship