You are on page 1of 5

1. What is SQL?

Structured Query Language is a database tool which is used to create and access database to
support software application.

2. What are the three types of SQL statement? List and describe them.
1) DDL (Data Definition Language): It is used to define the database structure such as tables. It
includes three statements such as Create, Alter, and Drop.
2) DML (Data Manipulation Language): These statements are used to manipulate the data in
records. Commonly used DML statements are Insert, Update, and Delete.
The Select statement is used as partial DML statement that is used to select all or relevant
records in the table.
3) DCL (Data Control Language): These statements are used to set privileges such as Grant
and Revoke database access permission to the specific user.

4. List some of database applications.


Some of the popular database applications are: Oracle, Sybase, MS Access, MS SQL Server,
Paradox, DB/2, Dbase, FoxPro, MySql
5. What are the elements of a database?
The major elements of a database are
Tables, Queries, Form, Reports, Macros, Modules

6. What is SQL injection?

SQL Injection is a type of database attack technique where malicious SQL statements are
inserted into an entry field of database such that once it is executed the database is opened for an
attacker. This technique is usually used for attacking Data-Driven Applications to have an access
to sensitive data and perform administrative tasks on databases.

7. What is the Primary key?


A Primary key is a column whose values uniquely identify every row in a table. Primary key
values can never be reused.

8. What are Foreign keys?

When a one table’s primary key field is added to related tables in order to create the common
field which relates the two tables, it called a foreign key in other tables.
Foreign Key constraints enforce referential integrity.

9. What is DBMS?
Database Management System is a collection of programs for managing data. It is system
software which enables the storage, modification, manipulation, and extraction of data from a
database.
It supports the varied users to CREATE, MANAGE, RETRIEVE, UPDATE, and STORE the
information.
10. List the 4 categories of Database which available in the market.
The four categories of Database available in the market include:
• Hierarchical Databases
• Network Databases
• Relational Databases

• Object-oriented Databases

11. List the advantage of Database Management System

High-security level

Presence of referential integrity

Consistency

Data Independence

The absence of redundancy

Enforcement of standards

Solves enterprise requirements

Backup and recovery of data

Develop data models

12. What the responsibility of Database Administrator?

 System / Application installation.


 Designs and documents database architecture
 Develops database utilities and automated reporting.
 Creates, tests, and executes data management languages
 Performs maintenance operations daily, weekly and monthly
 Implements and maintains database security and encryption
 Develops, manages and tests database and information system backup and recovery
plans.
 Database recovery in case of crash
 Identify staff’s problems and resolve it.
 Monitors all database resources.
 Update software, hardware and services.
13. Which of the following data types is used to attach Microsoft Office files, graphics files,
sound files, and pdf files to a table?
A. OLE object
B. Hyperlink
C. Text
D. Memo
ANSWER: A

12. Which of the following views contains command buttons that execute operations on entire
databases?
A. Layout view B. Backstage view C. Design view D. Datasheet view
ANSWER: B
13. List some of database applications.
Some of the popular database applications are: Oracle, Sybase, MS Access, MS SQL Server,
Paradox, DB/2, Dbase, FoxPro, MySql
14. What are the elements of a database?
The major elements of a database are
Tables, Queries, Form, Reports, Macros, Modules
15. Which one from the following is not Data Definition Language command?
A. Create B. Alter C. Insert D. Drop
Answer: C. Insert
Insert is Data Manipulation Language command
16. Which one of from the following commonly used constraints available in SQL?

A. Not Null B. Grant C. Revoke D. Select


Answer: A. Select
17. Which one of from the following not categories of data integrity exist with each RDBMS?
A. Entity Integrity B. Domain Integrity C. Referential integrity D. User-Defined Integrity E.
None
Answer: E. None
18. Which of the following is the preferred way to recover a database after a transaction in
progress terminates abnormally?
A. Rollback B.Rollforward C. Switch to duplicate database D. Reprocess transactions
Answer: A. Rollback
19. Concurrency control is important for which of the following reasons?
A. To ensure data integrity when updates occur to the database in a multiuser environment
B. To ensure data integrity when updates occur to the database in a single-user environment
C. To ensure data integrity while reading data occurs to the database in a multiuser
environment
D. To ensure data integrity while reading data occurs to the database in a single-user
environment
Answer: A

20. Which of the following is the preferred way to recover a database after a system failure?
A. Rollback
B. Rollforward
C. Switch to duplicate database
D. Reprocess transactions
Answer: C
21. What are different backups available in SQL Server?
Ans. Different possible backups are:
 Full backup
 Differential Backup
 Transactional Log Backup
 Copy Only Backup
 File and Filegroup backup
 Incremental backup
22. Which statement is wrong about PRIMARY KEY constraint in SQL?
A. The PRIMARY KEY uniquely identifies each record in a SQL database table
B. Primary key can be made based on multiple columns
C. Primary key must be made of any single columns
D. Primary keys must contain UNIQUE values.
Answer: C
Primary key of a table can be made based on single column or with combination of
multiple columns.
23. In a table, a column contains duplicate value, if you want to list all different value only, then
which SQL clause is used?
A. SQL DISTINCT
B. SQL UNIQUE
C. SQL BETWEEN
D. SQL Exists
Answer: A
DISTINCT keyword is used to fetch different (unique) value. UNIQUE keyword is known as
constraint that is applied to a table, e.g. if UNIQUE is applied to a column, that column will
allow only unique records to store and will not accept duplicate record.
24. Logical operators used in SQL are
A. AND, OR , NOT
B. &&, ||,!
C. $,|,!
D. None of the above
Answer: A
25. The command to eliminate a table from a database in SQL is:
A. REMOVE TABLE CUSTOMER;
B. DROP TABLE CUSTOMER;
C. DELETE TABLE CUSTOMER;
D. UPDATE TABLE CUSTOMER;
E. None
Answer: B
26. Which of the following is the correct order of keywords for SQL SELECT statements?
A.SELECT, WHERE, FROM
B. FROM, WHERE, SELECT
C.WHERE, FROM, SELECT
D. SELECT, FROM, WHERE
Answer: D
27. Which one of the following sorts rows in SQL?
A. SORT BY
B. ALIGN BY
C. ORDER BY
D. GROUP BY
Answer:C
28. Which one of the following statements is false?
A. The data dictionary is normally maintained by the database administrator.
B. Data elements in the database can be modified by changing the data dictionary.
C. The data dictionary contains the name and description of each data element.
D. The data dictionary is a tool used exclusively by the database administrator.
Answer: B

21. What are different backups available in SQL Server?


Ans. Different possible backups are:
 Full backup
 Differential Backup
 Transactional Log Backup
 Copy Only Backup
 File and File group backup
 Incremental backup

You might also like