Q: 1 Suppose X is a composite attribute of an entity type and has three components, A1, A2 and A3, where only A2 is multi-valued and can be NULL. If domain sets of A1, A2 and A3 have 5, 3, and 4 elements respectively, what is the size of the domain of X?
60
12
120
160
[ Option D ]
The attribute X is a composite attribute made up of three components, A1, A2, and A3, whose domain sizes are 5, 3, and 4 respectively. Since A2 is a multi-valued attribute, it can take multiple values from its domain or even be NULL.
If the domain of A2 has 3 elements, then the number of possible subsets of A2 is 23 = 8, because each element may be either included or not.
Now, the total number of possible combinations for X is calculated as:
Domain size of X = (Domain of A1) × (Domain of A2) × (Domain of A3)
Domain size of X = 5 × 8 × 4 = 160
Q: 2 What term refers to the complete logical definition of a database, including the description of all tables, fields, and relationships?
Schema
Data Repository
Data manipulation language
None of the above
[ Option A ]
A Schema represents the overall logical structure of a database. It includes definitions of all tables, fields or attributes, data types, and relationships among the tables. The schema acts as a blueprint that describes how data is organized in the database.
Q: 3 A group of associated fields is called a?
Attribute
Record
Field
Table
[ Option B ]
In a database, a field represents a single piece of data, such as a name or fees. When several related fields are combined together to describe a complete entity, they form a Record. For example, a student record may consist of fields like rollno, name, age, and course.
Q: 4 Which type of relationship requires an associative entity that has its own attributes?
One-to-One (1:1)
Many-to-Many (M:N)
One-to-Many (1:M)
All of the above
[ Option B ]
A Many-to-Many (M:N) relationship occurs when multiple records in one table are related to multiple records in another table. Such a relationship cannot be implemented directly in a relational database. To resolve this, an associative entity (junction table) is created.
THIS ASSOCIATIVE ENTITY:
Q: 5 In Relational Model, which type of constraint does not allow composite and multivalued attributes?
Entity integrity constraints
Domain constraints
Referential integrity constraints
Uniqueness constraints
[ Option B ]
In the Relational Model, every attribute in a table must store a single, indivisible value. This means the model does not allow composite attributes, which can be divided into sub-parts, or multivalued attributes, which can hold more than one value at the same time. The type of rule that enforces this requirement is known as a Domain Constraint.
Domain constraints define what type of values an attribute (column) can store. They ensure that:
Thus, domain constraints automatically prevent composite and multivalued attributes.
Q: 6 The cardinality of a relational table with 5000 rows and 10 columns is—
5000
10
500
50000
[ Option A ]
In a relational database table, Cardinality refers to the total number of rows or records present in the table. It represents how many individual data entries the table holds.
The Degree refers to the total number of columns or attributes in the table, which describe the structure of each record.
| Property | Value |
|---|---|
| Number of Rows (Cardinality) | 5000 |
| Number of Columns (Degree/Arity) | 10 |
Q: 7 The number of attributes in a relation is known as—
Features of the relation
Address of the relation
State of the relation
Degree of the relation
[ Option D ]
The number of attributes or columns in a relation is known as the Degree of the relation. Sometimes it is also called Arity.
Q: 8 The primary means of identifying entities within an entity set in a relational database is the:
Tuple
Pointer
Record
Primary Key
[ Option D ]
In a relational database, each entity (row or tuple) in a table is uniquely identified by a Primary Key.
Q: 9 An ________ is a person, place, thing, or event about which data is collected and maintained in a database.
Primary Key
Table
Record
Entity
[ Option D ]
In database terminology, an entity represents a real-world object such as a person, place, thing, or event for which data is stored in a database. Examples of entities include Student, Employee, Course, or Order.
Thank you so much for taking the time to read my Computer Science MCQs section carefully. Your support and interest mean a lot, and I truly appreciate you being part of this journey. Stay connected for more insights and updates! If you'd like to explore more tutorials and insights, check out my YouTube channel.
Don’t forget to subscribe and stay connected for future updates.