RSS Feed

Multiple Choice Questions on SQL Tables

Multiple Choice Questions on SQL Tables

1. The ................. statement is used to create a table in a database.

A) CREATE SQL TABLE
B) CREATE TABLE
C) CREATE SQL.TABLE
D) Both B and C

2. #table refers to a local temporary table and is visible to only the user who created it.

A) True
B) False

3. Which command to use in order to delete the data inside the table, and not the table itself

A) DELETE
B) TRUNCATE
C) Both TRUNCATE & DELETE
D) DROP

4. Transaction rollbacks affect Table variables

A) True
B) False

5. ##table refers to a ............. which is visible to all users.

A) table variables
B) persistent temporary tables
C) local temporary tables
D) global temporary table

6. Delete table and Drop table are not the same though. The ......... will delete all data from the table whilst the ....... will remove the table from the database.

A) Drop,Delete
B) Delete, Drop

7. Below Query shows:
USE DBName
GO
SELECT *
FROM sys.Tables
GO
A) List of system tables of Database
B) List of temporary tables of Database
C) List of all tables of Database
D) Both A & B

8. sp_tables returns only the views in the database.

A) True
B) False

9. In order to modify system tables you can use: A) sp_configure B) sp_modify C) sp_allow_updates D) Both A & B 10. ......... and ......... system tables maintain entries containing object definitions and other tracking information for each object.

A) sysobjects
B) syscomments
C) systrack
D) Both A & B

Answers