0% found this document useful (0 votes)
47 views17 pages

Fundamenta of Database

Uploaded by

sirnesateshome
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
47 views17 pages

Fundamenta of Database

Uploaded by

sirnesateshome
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 17

1.

Which one of the following provides the ability to query information from the
database and to insert tuples into, delete tuples from, and modify tuples in the
database?
a) DML(Data Manipulation Langauge)
b) DDL(Data Definition Langauge)
c) Query
d) Relational Schema

2. Which command is used to modifies an existing database object, such as a


table?
A. Create
B. Alter
C. Drop
D. Modify

3. Which command is used to modifies records?


A. Insert
B. Update
C. Delete
D. Modify

4. Which command list names and files of attached databases?


A. db
B. use
C. .database
D. database

5. What is an RDBMS?
a) Database that stores data elements that are not linked
b) Database that accesses data elements that are not linked
c) Database that stores and allows access to data elements that are linked
d) None of the mentioned

6. What is a relation in RDBMS?


a) Key
b) Table
c) Row
d) Data Types
7. Which of the following systems use RDMS?
a) Oracle
b) Microsoft SQLServer
c) IBM
d) All of the mentioned

8. Relational Algebra is a __________ query language that takes two relations as


input and produces another relation as an output of the query.
a) Relational
b) Structural
c) Procedural
d) Fundamental

9. Which of the following is a fundamental operation in relational algebra?


a) Set intersection
b) Natural join
c) Assignment
d) None of the mentioned

10. Which of the following is used to denote the selection operation in relational
algebra?
a) Pi (Greek)
b) Sigma (Greek)
c) Lambda (Greek)
d) Omega (Greek)

11. The ___________ operation, denoted by −, allows us to find tuples that are in
one relation but are not in another.
a) Union
b) Set-difference
c) Difference
d) Intersection
12. Which one of the following is used to define the structure of the relation,
deleting relations and relating schemas?
a) DML(Data Manipulation Langauge)
b) DDL(Data Definition Langauge)
c) Query
d) Relational Schema

13. CREATE TABLE employee (name VARCHAR, id INTEGER)


What type of statement is this?
a) DML
b) DDL
c) View
d) Integrity constraint

SELECT * FROM employee

14. What type of statement is this?


a) DML
b) DDL
c) View
d) Integrity constraint

15. The basic data type char(n) is a _____ length character string and varchar(n)
is _____ length character.
a) Fixed, equal
b) Equal, variable
c) Fixed, variable
d) Variable, equal

16. To remove a relation from an SQL database, we use the ______ command.
a) Delete
b) Purge
c) Remove
d) Drop table

17.
DELETE FROM r; //r - relation
This command performs which of the following action?
a) Remove relation
b) Clear relation entries
c) Delete fields
d) Delete rows

18.
INSERT INTO instructor VALUES (10211, ’Smith’, ’Biology’, 66000);
What type of statement is this?
a) Query
b) DML
c) Relational
d) DDL
19. Which of the join operations do not preserve non-matched tuples?
a) Left outer join
b) Right outer join
c) Inner join
d) Natural join

20. What type of join is needed when you wish to include rows that do not have
matching values?
a) Equi-join
b) Natural join
c) Outer join
d) All of the mentioned

21. How many tables may be included with a join?


a) One
b) Two
c) Three
d) All of the mentioned

22. Which are the join types in join condition:


a) Cross join
b) Natural join
c) Join with USING clause
d) All of the mentioned

23. The operation which is not considered a basic operation of relational algebra
is
a) Join
b) Selection
c) Union
d) Cross product

24. A many to many relationship between two entities usually results in how
many tables?

A. One
B. Two
C. Three
D. Four
25. An ________ is a set of entities of the same type that share the same
properties, or attributes.

A. Entity set
B. Attribute set
C. Relation set
D. Entity model
26. Entity is a _________

A. Object of relation
B. Present working model
C. Thing in real world
D. Model of relation

27. E-R modeling technique is a :

A. Top-down approach
B. Bottom-up approach
C. Left-right approach
D. None of the above

28. The number of entities to which another entity can be associated via a
relationship set is expressed as :

A. Entity
B. Cardinality
C. Schema
D. Attributes

29. Relations produced from an E-R model will always be in :

A. First normal form


B. Second normal form
C. Third normal form
D. Fourth normal form

30. In ER model the details of the entities are hidden from the user. This process
is called :

A. generalization
B. specialization
C. abstraction
D. none of these above
31. The attributes made up of more than one single attributes are called

A. Composite attribute
B. Derived attribute
C. Single value attribute
D. Multi value attribute

32. The attribute AGE is calculated from DATE_OF_BIRTH. The attribute AGE
is

A. Single valued
B. Multi valued
C. Composite
D. Derived
33. Which of the following can be a multivalued attribute?

A. Phone_number
B. Name
C. Date_of_birth
D. All of the mentioned

34. Which of the following is a single valued attribute?

A. Register_number
B. Address
C. SUBJECT_TAKEN
D. Reference

35. An association of several entities in an Entity-Relation model is called :

A. Tuple
B. Record
C. Relationship
D. Field

36. To include integrity constraint in an existing relation use:

A. Modify table
B. Drop table
C. Alter table
D. Create table

37. which of the following is not an integrity constraint?

A. Not null
B. Positive
C. Unique
D. Check predicate

38. Foreign key is the one in which the ________ of one relation is referenced in
another relation.

A. Foreign key
B. Primary key
C. References
D. Check constraint
39. Data integrity constraints are used to:

A. Control who is allowed access to the data


B. Ensure that duplicate records are not entered into the table
C. Improve the quality of data entered for a specific property (i.e., table
column)
D. Prevent users from changing the values stored in the table

40. The relationship between the two tables are created using __________

A. Candidate Key
B. Primary Key
C. Foreign Key
D. Check Constraint

41. The Entity Customer has three candidate keys: a) CustId b) Email and c)
ContactNo. Suggest the best primary key for this entity.

A. CustId
B. Email
C. ContactNo
D. CustId and ContactNo

42. Which of the following statement(s) is/are FALSE about primary key?

A. There can be more than one primary key for a table


B. Columns with string data types cannot be made Primary Key because they are
large
C. Both A and B
D. None of the above
43. Which is the subset of SQL commands used to manipulate Oracle Database
structures, including tables?

A. Data Definition Language(DDL)


B. Data Manipulation Language(DML)
C. DML and DDL
D. None of the Mentioned

44. In SQL, which of the following is not a data definition language commands?

A. RENAME
B. REVOKE
C. GRANT
D. UPDATE

45. Which command allows the removal of all rows from a table but flushes a
table more efficiently since no rollback information is retained:

A. TRUNCATE command
B. Create command
C. Drop table command
D. Alter table command

46. Which of the following statement removes database including its related
components?

A. DROP DATABASE
B. DELETE DATABASE
C. REMOVE DATABASE
D. None of the mentioned

47. Which of the following statement removes sales and suppliers database?

A. DROP DATABASE Sales, NewSales


B. DROP DATABASE Sales, suppliers
C. DROP DATABASE Sales and suppliers
D. DROP DATABASE Sales-suppliers
48. Command that is used to add attributes to an existing relation, is said to be

A. Alter
B. Modify
C. Tailor
D. Eliminate
49. To delete a particular column in a relation the command used is:

A. UPDATE TABLE
B. TRUNCATE COLUMN
C. ALTER, DROP
D. DELETE COLUMN

50. Which one of these is used with SELECT clause to fetch all columns from a
table?

A. ALL
B. *
C. DISTINCT
D. AS

51. Which of the following columns in a table cannot be updated?

A. DATE type columns in the table


B. Columns which allows NULL values in the table
C. A primary key column which also serves as foreign key reference in
another table
D. All of the above

52. The language used application programs to request data from the DBMS is
referred to as __________

A. DML
B. DDL
C. Query language
D. All of the Mentioned

53. Which of the following is not included in DML (Data Manipulation


Language)?

A. Insert
B. Update
C. Delete
D. Alter
54. TRUNCATE statement in SQL is a

A. DDL
B. DML
C. DCL
D. TCL

55. A type of query that is placed within a WHERE or HAVING clause of


another query is called

A. Master query
B. Sub query
C. Super query
D. Multi-query

56. A data manipulation command the combines the records from one or more
tables is called

A. SELECT
B. PROJECT
C. JOIN
D. PRODUCT

57. Select the sequence for how the query mechanism works?

A. Authentication-> DDL->DML->query optimizer->output


B. DDL->DML->query optimizer-> Authentication->output
C. DML->query optimizer-> Authentication-> DDL-> output
D. All of the mentioned

58. Data manipulation language (DML) includes statements that modify the
_____ of a database.

A. Structure
B. Data
C. User
D. Size
59. Values of one type can be converted to another domain using which of the
following ?

A. Cast
B. Drop type
C. Alter type
D. Convert

60. To combine multiple retrievals, we write several SELECT statements and put
the keyword between them. What is the keyword?

61. A. COMBINE
B. CONCAT
C. JOIN
D. UNION

62. What is xyz in the following SQL statement? SELECT xyz FROM table1
UNION xyz FROM table2;

A. row name
B. column name
C. table name
D. database name

63. Which keyword used with UNION does not retain duplicate rows?

A. ALL
B. NARROW
C. STRICT
D. DISTINCT

64. The database design prevents some data from being stored due to _______.

A. Deletion anomalies
B. Insertion anomalies
C. Update anomalies
D. Selection anomalies
65. ____is a database schema that depicts key dependencies between the primary
key and foreign key

A. ER Diagram

B. Database Diagram

C. Schema Diagram

D. Relational Schema

66. In ER diagram Diamond/Ellipses represent

a. Relationship sets/Attributes

b. Entity sets/Attributes

c. Attributes/Relationships sets

d. Relationship sets/Entity sets

67. A relation is in 2NF if:

A. All the values of non-key attributes are dependent fully on the candidate key.
B. Any non-key attribute that are dependent on only part of the candidate key
should be moved to another relation where the partial key is the actual full key.
C. It must be already in the 1NF.
D. All of the above.

68. If one attribute is determinant of second, which in turn is determinant of


third, then the relation cannot be:

A. Well-structured
B. 1NF
C. 2NF
D. 3NF
69. Consider the relation Sale(Date, Customer, Product, Vendor, VendorCity,
SalesRep)
{Date, Customer, Product} is the composite candidate key and the following
functional dependencies are also given:
Vendor => VendorCity, Product => Vendor
What is the highest normal form of the sale relation?

A. 0NF
B. 1NF
C. 2NF
D. 3NF

70. Third normal form is based on the concept of _________

A. Closure Dependency
B. Transitive Dependency
C. Normal Dependency
D. Functional Dependency

71. Which of the following statements does not change the state of the database?

A. Where
B. Select
C. Insert
D. Drop

You might also like