250+ TOP MCQs on System Variables and Answers

MySQL Database Multiple Choice Questions on “System Variables”.

1. Which system variable when set to 1, makes all temporary tables to get stored on disk rather than in memory?
a) basedir
b) back_log
c) big_tables
d) bind_address

Answer: c
Clarification: The variable ‘big_tables’ if set to 1, all temporary tables are stored on disk rather than in memory. This is a little slower but the error ‘The table tbl_name is full’ does not occur for SELECT operations that require a large temporary table.

2. The permitted value type for the variable ‘character_set_client’ is _____________
a) integer
b) float
c) double
d) string

Answer: d
Clarification: ‘character_set_client’ is the character set for statements that arrive from the client. The session value of this variable is set using the character set requested by the client when client connects to server.

3. ‘character_set_database’ represents the character set used by the default database.
a) True
b) False

Answer: a
Clarification: ‘character_set_database’ is the character set used by the default database. The server sets the variable whenever the default database changes. If there is no default database the variable has the same value as ‘character_set_server’.

4. Which string function returns the index of the first occurrence of substring?
a) INSERT()
b) INSTR()
c) INSTRING()
d) INFSTR()

Answer: b
Clarification: The string funtion ‘INSTR()’ is used to return the index of the first occurrence of the substring. The function ‘INSERT()’ is used to insert a substring at the specified position up to the specified number of characters.

5. Which module links DBI to the web?
a) CGI.pn
b) CGI.pem
c) CGI.pm
d) CGI.po

  250+ TOP MCQs on Operators and Answers

Answer: c
Clarification: The CGI.pm module is used to write scripts that use the ‘Common Gateway Interface’ protocol. It defines how a web server communicates with other programs. It provides an easy link.

6. What does CGI stand for?
a) Computer Gateway Interface
b) Common Gateway Interface
c) Computer Generated Interface
d) Common Generated Interface

Answer: b
Clarification: The ‘CGI.pm’ module is so called because it helps write scripts that use the ‘Common Gateway Interface’ protocol which defines how a web server communicates with other programs.

7. The line that is written at the top of the script to write a Perl script using CGI.pm is ___________
a) use this CGI
b) put CGI
c) use CGI
d) include CGI

Answer: c
Clarification: In order to write a Perl script that uses the ‘CGI.pm’ module, a ‘use CGI’ statement is included near the beginning of the script that imports the function names of the module.

8. What is the shebang line?
a) #!
b) !#
c) #$
d) $#

Answer: a
Clarification: The Perl scripts are text files, which can be ceated using any text editor. All Perl scripts generally begin with a #! (shebang) line. A script is a file containing a sequence of commands.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top