0% found this document useful (0 votes)
47 views

Computer 12 CH03 Notes

The document discusses the key steps in the database design process, including feasibility study, requirements analysis, data analysis, data modeling, and defining relationships and cardinality. The analysis stage involves studying the current system and determining if a new database system is feasible. Requirements analysis identifies user needs, and data analysis models the data through tools like data flow diagrams, decision tables, and decision trees. Data modeling represents real-world entities and relationships between them using objects, attributes, and connections. Relationships can be one-to-one, one-to-many, many-to-many, and define how entities are logically linked. Cardinality specifies the number of occurrences of one entity related to another.

Uploaded by

Subh Zil
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
47 views

Computer 12 CH03 Notes

The document discusses the key steps in the database design process, including feasibility study, requirements analysis, data analysis, data modeling, and defining relationships and cardinality. The analysis stage involves studying the current system and determining if a new database system is feasible. Requirements analysis identifies user needs, and data analysis models the data through tools like data flow diagrams, decision tables, and decision trees. Data modeling represents real-world entities and relationships between them using objects, attributes, and connections. Relationships can be one-to-one, one-to-many, many-to-many, and define how entities are logically linked. Cardinality specifies the number of occurrences of one entity related to another.

Uploaded by

Subh Zil
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

DATABASE DESIGN PROCESS

Q1. What are the different steps involved in analysis stage while designing a
database?
Ans.
The process of study the current system is called analysis. While designing a
database we must consider the following steps. These steps are used at analysis stage
while designing a database.
• Feasibility study
o A feasibility study is a preliminary study which determines and documents a
database's practicality.
o Before developing a new system it is analyzed that either the new system
economically, technically and operationally feasible or not. The results of this
study includes:
 The area of identification and selection of boundaries of the
database.
 What is the cost of new system?
 How much time is required to complete the system?
 What the new system will return?
 How much funds are allocated?
 Alternate solutions are considered.
 The results of this study are used to make a decision whether to
proceed with the project or not.
 During this process market analysis is also conducted.
o After the project is selected funds are allocated and planning is started.
[Ch#3] Database Design Process 54 Computer Science Part-II
• Requirements analysis
o Systematic requirements analysis is also known as requirements engineering.
o It is sometimes referred by names such as requirements gathering, requirements
capturing, or requirements specification.
o Requirements must be measurable, testable, related to identified business needs or
opportunities, and defined to a level of detail sufficient for system design.
Conceptually, requirements analysis includes three types of activity:
Eliciting requirements:
The task of communicating with customers and users to determine what their
requirements are?
Analyzing requirements:
Determining whether the stated requirements are unclear, incomplete, ambiguous,
or contradictory, and then resolving these issues.
Recording requirements:
Requirements may be documented in various forms, such as natural-language
documents, use cases, user stories, or process specifications.
• Project planning
o Project planning is part of project management.
o Initially the project scope is defined and the appropriate methods for completing
the project are determined.
o Following this step, the durations for the various tasks necessary to complete the
work are listed and grouped into a work breakdown structure.
o The logical dependencies between tasks are defined using an activity network
diagram that enables identification of the critical path.
o Then the necessary resources can be estimated and costs for each activity can be
allocated to each resource, giving the total project cost. e.g. salaries of
development team, traveling expenses, cost of hardware equipments etc.
o At this stage, the project plan may be optimized to achieve the appropriate
balance between resource usage and project duration to comply with the project
objectives.
• Data analysis
While designing a database it is very important to analyze the data which is required
to be stored in the database. There are three activities in this phase
DFD (Data Flow Diagrams):
o A data flow diagram (DFD) is a graphical representation of the "flow" of data
through an information system.
o A data flow diagram can also be used for the visualization of data processing
(structured design).
[Ch#3] Database Design Process 55 Computer Science Part-II
Decision Tables:
o Decision tables are a precise yet compact way to model complicated logic.
o Decision tables, like if-then-else and switch-case statements, associate conditions
with actions to perform.
Decision Trees:
A decision tree is a decision support tool that uses a graph or model of decisions
and their possible consequences.
Q2. What is data modeling? Also discuss its components / ingredients?
Ans.
Data Modeling
o A representation of real world objects or events and their association is called
model and the identification of data objects and their relationships to other data
objects is called data modeling.
o Data modeling is the first step in database design.
o Data modeling helps us to understand the complexity of the system.
o Designers first create a conceptual model of how data items relate to each other.
o Data modeling involves a progression from conceptual model to logical model to
physical schema.
Ingredients of Data Modeling
1. Entity/Object
o Anything about which we want to store data is called
entity.
o It is participating in the system and it can be a person,
EMPLOYEE
place or an event.
o Entity is represented as a rectangle.
o Name of an entity is in capital letters.
o Each occurrence of an entity is also called an instance of entity. Each instance of
an entity is unique. It is identifiable by the primary key.
2. Attributes
o Attributes are properties of an entity for example an EMPLOYEE has a name,
address, telephone number etc.
Name Address Telephone

EMPLOYEE

o All these are called the attributes of the entity.


[Ch#3] Database Design Process 56 Computer Science Part-II
o Attributes are represented by an oval and name is written inside the shape.
3. Relationships
o A logical connection between two entities is called relationship.
o The relationship indicates how the entities are connected or related to each other.
o The name of relationship is displayed over the line that represents the type of
connection.
o Relationship is written within a diamond.
Orders
Displays

Stocks
BOOK BOOK STORE
Sells

Returns

Above figure shows different connections between BOOK and BOOK STORE.
• A BOOK STORE orders BOOK(S)
• A BOOK STORE displays BOOK(S)
• A BOOK STORE stocks BOOK(S)
• A BOOK STORE sells BOOK(S)
• A BOOK STORE returns BOOK(S)

BOOK STORE ORDER BOOK

Some important points about relationships


o All relationships define the relevant connections between two entities.
o All relationships are bi-directional
o Only relevant relationships according to the requirement are considered.
o The types of relationship are.
 One to one.
 One to many.
 Many to many.
 Recursive.
[Ch#3] Database Design Process 57 Computer Science Part-II
 None
Q3. What are relationships and what are their types?
Ans. Relationships
• A logical connection between two entities is called relationship.
• The relationship indicates how the entities are connected or related to each other.
• The name of relationship is displayed over the line that represents the type of
connection.
• All relationships define the relevant connections between two entities.
• All relationships are bi-directional
• Only relevant relationships according to the requirement are considered.
• The relationship can be
• One to One:
o One instance of first entity is related to exactly one instance of second
entity. e.g. A country must have a capital and it must be only for one
country.

EMPLOYEE has VHICLE

• One to Many:
o One instance of first entity is related to zero, one or may instances of
second entity. e.g. A father can have many children but all children must
have only one father.

ROOM has STUDENT

• Many to Many:
o One or many instances of first entity are related to one or many instances
of second entity. e.g. a student have many courses to study and similarly a
course can be studied by many students.
[Ch#3] Database Design Process 58 Computer Science Part-II

STUDENT join CLUB


[Ch#3] Database Design Process 59 Computer Science Part-II

Q4. What is cardinality? Explain briefly.


Ans. Cardinality
• The number of entity occurrences of first entity is related with one or more
occurrence of the second entity is known as cardinality.
• It is expressed as one or many e.g. a country can have many cities but a country
can have only one capital.
• The cardinality of one is denoted by a short vertical line drawn across the
relationship line.
• The cardinality of many is denoted by the line end that splits into three parts. This
symbol is also called “Crow’s Foot”.
• Small circle represent the zero number of record.
• The cardinality of relationship can be
o One to one
o One to many
o Many to many
o Recursive
o None

Each instance of A is related to a minimum of zero and a


maximum of one instance of B.

Each instance of B is related to a minimum of one and a


maximum of one instance of A.

Each instance of A is related to a minimum of one and a


maximum of many instances of B.

Each instance of B is related to a minimum of zero and a


maximum of many instances of A.

You might also like