This set of SQL Server Multiple Choice Questions & Answers (MCQs) focuses on “Data Definition Language – 3”.
1. Point out the wrong statement with respect to ALTER INDEX statement.
a) Adds new format for specifying index and table names
b) Adds the index option:MAXDOP
c) Adds the index option:ONLINE
d) None of the mentioned
View Answer
Explanation: Options provided are features of DROP index and CREATE index statements.
2. Which of the following adds MOVE TO clause?
a) DROP INDEX
b) ALTER INDEX
c) UPDATE INDEX
d) CREATE INDEX
View Answer
Explanation: DROP INDEX statement enables moving data from a clustered index to another filegroup or partition scheme.
3. Which is a new DDL statement?
a) DROP ROLES
b) CREATE APPLICATION ROLE
c) CREATE USERS
d) None of the mentioned
View Answer
Explanation: Application role creation changes the properties of an application role.
4. Which of the following creates a new Microsoft Windows or SQL Server login account?
a) CREATE LOGIN
b) DROP LOGIN
c) UPDATE LOGIN
d) REMOVE LOGIN
View Answer
Explanation: CREATE login generates a new SQL Server login.
5. Statement used to remove a user from the current database is ____________
a) DROP ROLE
b) DROP USER
c) DROP LOGIN
d) None of the mentioned
View Answer
Explanation: DROP USER is used to delete the user account from the database.
6. Command used to modify the schema is __________
a) ALTER SCHEMA
b) ALTER STRUCTURE
c) ALTER VIEW
d) DBCC SHRINKDB
View Answer
Explanation: ALTER SCHEMA changes the owner of a schema.
7. Creation of new database role in the current database is made by __________
a) CREATE APPLICATION ROLE
b) CREATE ROLE
c) CREATE USER
d) CREATE LOGIN
View Answer
Explanation: CREATE ROLE generates a new role in the database.
8. Purpose of ALTER CERTIFICATE is __________
a) Adds a private key to a certificate
b) Changes the public key of a certificate
c) Removes the certificate from the database
d) None of the mentioned
View Answer
Explanation: ALTER CERTIFICATE changes the private key used to encrypt a certificate.
9. DDL statements not used for Synonym is __________
a) CREATE SYNONYM
b) DROP SYNONYM
c) ALTER SYNONYM
d) None of the mentioned
View Answer
Explanation: Synonyms allow client applications to use the single-part name of a synonym to reference a base object.
10. Which of the following statement drops the synonym?
a) DELETE SYNONYM
b) DROP SYNONYM
c) REMOVE SYNONYM
d) None of the mentioned
View Answer
Explanation: DROP SYNONYM deletes an existing synonym.
Sanfoundry Global Education & Learning Series – SQL Server.
To practice all areas of SQL Server, here is complete set of 1000+ Multiple Choice Questions and Answers.
If you find a mistake in question / option / answer, kindly take a screenshot and email to [email protected]
- Apply for Programming Internship
- Check SQL Server Books
- Practice Programming MCQs
- Check Information Technology Books