R4RIN
MCQS
SQL MCQ Quiz Hub
SQL MCQ SET 15
Choose a topic to test your knowledge and improve your SQL skills
1. Which MySQL statement is used to find out which character sets are available?
SHOW CHARACTER SET
SHOW COLLATION
SHOW CHARACTER SETS
SHOW COLLATIONS
2. Which collations does this MySQL statement list?
names beginning with utf8
names ending with utf8
names containing utf8% anywhere
names ending in utf8%
3. Which statement is used to show the server’s current character set and collation settings?
SHOW CONSTANTS
SHOW CONSTRAINTS
SHOW VARIABLES
DISP VARIABLES
4. What does UTF stand for int utf8?
Universal Transformation Format
Unicode Transformation Format
Universal Transformation Formula
Unicode Transformation Formula
5. Prior to MySQL 6.0, utf8 was ___________
3 bytes
4 bytes
8 bytes
9 bytes
6. Post MySQL 6.0, utf8 was ___________
3 bytes
4 bytes
5 bytes
6 bytes
7. What is generally used as a synonym for CHARACTER SET?
CSET
CHSET
CHARSET
CHCSET
8. Which statement is used to select a default database?
USE
CREATE
DROP
SCHEMA
9. Which keyword is the synonym for DATABASE?
TABLE
OBJECT
DB
SCHEMA
10. Which keyword is used to create a database?
CREATE
SET
SETUP
LINK
11. The file created by the server to store the database attributes is __________
db.otp
dp.zip
db.opt
db.cls
12. To create a database only if it doesn’t already exist, which clause is used?
IF EXISTS
IF NOT EXISTS
CREATE EXISTS
EXISTS IF
13. MySQL stores the database character set and collation attributes in the file _________
dp.opt
db.opt
db.sv
db.zip
14. Which statement is used to see the definition for an existing database?
SHOW CREATE DATABASE
SHOW DATABASE
SHOW CREATE
SHOW CREATE DATABASE TABLE
15. Which statement makes changes to the database’s global attributes?
CHANGE
ALTER
ALTERNATE
UPDATE
16. Which statement is used to remove indexes on tables?
DROP INDEX
DELETE INDEX
REMOVE INDEX
FLUSH INDEX
17. Which storage engine is not available in MySQL 5.0?
InnoDB
ARCHIVE
Falcon
NDB
18. The default storage engine used is ____________
EXAMPLE
ARCHIVE
MyISAM
NDB
19. What is the name of the format file for a table named my_tbl?
my_tbl.fmt
my_tbl.frm
my_tbl.fmr
my_tbl.ftm
20. Which keyword is used to create a table as a temporary copy of itself?
TEMP
TEMPO
TEMPR
TEMPORARY
21. Which storage engine enables to access tables from a MySQL server managed by another server?
InnoDB
EXAMPLE
MyISAM
FEDERATED
22. The default index type for MEMORY tables is __________
HASH
SPATIAL
FULLTEXT
UNIQUE
23. The statement to change the table name is __________
CHANGE
CHANGENAME
CHANGENM
RENAME
24. The general term for information about databases and the objects in MySQL is _________
datum
info
record
metadata
25. Which statement is used to determine the storage engine for individual tables?
SHOW STATUS OF TABLE
SHOW STATUS TABLE
SHOW TABLE STATUS
SHOW DEFAULT STATUS
26. Which disk data does FILES table in INFORMATION_SCHEMA store?
NDB
NBD
NBK
NCD
27. The information about table index characteristics is stored in which table of INFORMATION_SCHEMA?
FILES
STATISTICS
SCHEMATA
VIEWS
28. Which table in INFORMATION_SCHEMA stores information about storage engines and server plugins?
ENGINES, PLUGINS
FILES, PLUGINS
ENGINES, FILES
PLUGINS, STATISTICS
29. Which table stores information about the threads executing within the server?
PROCESS
PROCESSLIST
LIST
THREADSLIST
30. The command which lists databases managed by the server is _____________
mysqld
mysqlshow
mysqllist
mysqldb
31. The option in mysqlshow to show information about indexes in a table is _________
–no-data
–indexes
–keys
–flag
32. SELECT select_list FROM table_list WHERE row_constraint GROUP BY grouping_columns; Which of these is not optional?
select_list
table_list
row_constraint
grouping_columns
33. The join where all possible row combinations are produced is called _________
INNER JOIN
OUTER
NATURAL
CARTESIAN
34. The clause that filters JOIN results is called _________
WHERE
SORT
GROUP
GROUP BY
35. CROSS JOIN and JOIN are similar to __________
INNER JOIN
NATURAL JOIN
OUTER JOIN
CARTESIAN JOIN
36. The left and right joins are also known as __________
INNER JOIN
NATURAL JOIN
OUTER JOIN
CARTESIAN JOIN
37. What is joining a table to itself called?
COMPLETE
SELF
OBSOLETE
CROSS
38. In which join all the rows from the left table appear in the output irrespective of the content of the other table?
RIGHT JOIN
LEFT JOIN
INNER JOIN
OUTER JOIN
39. The join in which all the rows from the right table appear in the output irrespective of the content of the other table is ___________
CARTESIAN JOIN
CROSS JOIN
INNER JOIN
RIGHT JOIN
40. The facility that allows nesting one select statement into another is called __________
nesting
binding
subquerying
encapsulating
41. Which subquery returns a single value?
scalar
column
row
table
42. Which operators are used when a subquery returns multiple rows to be evaluated in comparison to the outer query?
IN and NOT IN
EXISTS and NOT EXISTS
OUTER JOIN and INNER JOIN
LEFT JOIN and RIGHT JOIN
43. The ALL subquery performs which operation?
row
column
table
database
44. Which of these operators perform similar operations like ALL and ANY?
SOME
MANY
SELECT
GROUP
45. Which operators test whether a subquery returns any rows?
IN and NOT IN
EXISTS and NOT EXISTS
PRESENT
ABSENT
46. Which subquery cannot be executed by itself as a separate statement?
Correlated
Uncorrelated
EXISTS
NOT EXISTS
47. Which of these operators does not perform relative-value comparisons?
=
==
<=
>=
48. To combine multiple retrievals, we write several SELECT statements and put the keyword between them. What is the keyword?
COMBINE
CONCAT
JOIN
UNION
49. What is ‘xyz’ in the following SQL statement?
row name
column name
table name
database name
50. Which keyword used with UNION does not retain duplicate rows?
ALL
NARROW
STRICT
DISTINCT
Submit