Anda di halaman 1dari 4

Q1. Describe two alternatives for specifying structural constraints on relationship types.

What are
the advantages and disadvantages?

Cardinality ratio: The cardinality ratio for a binary relationship specifies the maximum number
of relationship instances that an entity can participate in. For example, in the WORKS_FOR
binary relationship type, DEPARTMENT: EMPLOYEE is of cardinality ratio l:N, meaning that
each department can be related to (that is, employs) any number of employees, but an employee
can be related to (work for) only one department. The possible cardinality ratios for binary
relationship types are 1:1, l:N, N:l, and M:N.

Participation constraint: The participation constraint specifies whether the existence of an


entity depends on its being related to another entity via the relationship type. This constraint
specifies the minimum number of relationship instances that each entity can participate in, and is
sometimes called the minimum cardinality constraint. There are two types of participation
constraints-total and partial.

Q2. Can an identifying relationship of a weak entity type be of a degree greater than two? Give
examples to illustrate your answer

• A2. Weak Entity is an entity that cannot be uniquely identified by its attributes alone;
therefore, it must use a foreign key in conjunction with its attributes to create a primary
key. The foreign key is typically a primary key of an entity it is related to. A weak entity
type is one without any key attributes of its own. Entities belonging to a weak entity
type are identified by being related to another entity type ( called identifying owner)
through a relationship type ( called identifying relationship), in combination with values
of a set of its own attributes (called partial key). A weak entity type has total participation
constraint w.r.t. its identifying relationship.

Q3. List the different types of database models.Name the two legacy data models and two
subsequent data models that have been commercially implemented.

A 3 .The list of different database model are :

1 Flat model
2 Hierarchical model
3 Network model
4 Relational model
5 Dimensional model
6 Objectional database model

Part-B

Q4. what is specialisation on an entity type? What is its contribution toward improving the
modeling of the entity type considered?

A 4. Attributes define the possible properties for entities of an entity type.. The attribute type
describes the function of an attribute (for example, whether an attribute is a key attribute).

The concept of specializations and generalizations allows the formation of entity type subtypes.
There are a number of ways in which an entity type can be specialized. The criterion used for the
specialization is defined by the specialization category. Specializations are linked by the
specialization category to the source entity type

The generalization contains the attributes that are common to all entities of an entity type. These
attributes are inherited by the specializations and may be supplemented by other specific
attributes.In the university example the generalization People at the university has the
attributes Number, Name, and Address of a university member, which it passes on to its
specializations (Students, Professors, and so on). The specialization Students also has the
following attributes: Matriculation number, Assigned professor, and Course start.

• disjoint:

Each entity of the generalization occurs in a maximum of one specialization of the


category.The specialization category Activity is complete in the university example, since
each university member belongs to at least one specialization. This specialization
category is not disjoint, however, since it is conceivable that a person might be at the
same time both a student and a research assistant with the result that they would occur in
both specializations.A specialization category need be neither complete nor disjoint.

Q5. Consider an E-R diagram for library,where books are issued to borrowers. Borrowers can be
staff or student.Each book is written by a particular author?
A 5..The ER diagram is given below…

Q6. “There are a number of database models available in Database Management


System”.Why there is need of these models. Explain your answer by comparing
all the models

A 6.. Data modeling play an important part for any database making and it is real word data
environment.. Translating business logic into tables, columns, and relations is called data
modeling.by using data model we easily communicate between programmer and enduser..

Flat model: This may not strictly qualify as a data model. The flat (or table) model consists of a
single, two-dimensional array of data elements, where all members of a given column are
assumed to be similar values, and all members of a row are assumed to be related to one another.

Hierarchical model: In this model data is organized into a tree-like structure, implying a single
upward link in each record to describe the nesting, and a sort field to keep the records in a
particular order in each same-level list.
Network model: This model organizes data using two fundamental constructs, called records and
sets. Records contain fields, and sets define one-to-many relationships between records: one
owner, many members.

Relational model: is a database model based on first-order predicate logic. Its core idea is to
describe a database as a collection of predicates over a finite set of predicate variables,
describing constraints on the possible values and combinations of values.

Anda mungkin juga menyukai