DBMS Notes
DBMS Notes
DEPARTMENT OF COMPUTER
SCIENCE AND ENGINEERING
Study Material
GPCSET-401 – D.B.M.S
for
Diploma – IV Semester
DBMS
UNIT I: Introduction to DBMS Concepts
There are different fields where a database management system is utilized. Following are a few
applications which utilize the information base administration framework –
1. Railway Reservation System –
In the rail route reservation framework, the information base is needed to store the record or
information of ticket appointments, status about train’s appearance, and flight. Additionally,
if trains get late, individuals become acquainted with it through the information base update.
3. Banking –
Database the executive’s framework is utilized to store the exchange data of the client in the
information base.
4. Education Sector –
Presently, assessments are led online by numerous schools and colleges. They deal with all
assessment information through the data set administration framework (DBMS). In spite of
that understudy’s enlistments subtleties, grades, courses, expense, participation, results, and
so forth all the data is put away in the information base.
7. Broadcast communications –
Without DBMS any media transmission organization can’t think. The Database the
executive’s framework is fundamental for these organizations to store the call subtleties
and month to month postpaid bills in the information base.
8. Account –
The information base administration framework is utilized for putting away data about
deals, holding and acquisition of monetary instruments, for example, stocks and bonds in
a data set.
9. Online Shopping –
These days, web-based shopping has become a major pattern. Nobody needs to visit the
shop and burn through their time. Everybody needs to shop through web based shopping
sites, (for example, Amazon, Flipkart, Snapdeal) from home. So all the items are sold and
added uniquely with the assistance of the information base administration framework
(DBMS). Receipt charges, installments, buy data these are finished with the assistance of
DBMS.
11. Manufacturing –
Manufacturing organizations make various kinds of items and deal them consistently. To
keep the data about their items like bills, acquisition of the item, amount, inventory
network the executives, information base administration framework (DBMS) is utilized.
There are the following differences between DBMS and File systems:
Sharing of data Due to the centralized Data is distributed in many files, and it may
approach, data sharing is be of different formats, so it isn't easy to
easy. share data.
Data DBMS gives an abstract The file system provides the detail of the
Abstraction view of data that hides the data representation and storage of data.
details.
Security and DBMS provides a good It isn't easy to protect a file under the file
Protection protection mechanism. system.
Recovery DBMS provides a crash The file system doesn't have a crash
Mechanism recovery mechanism, i.e., mechanism, i.e., if the system crashes while
DBMS protects the user entering some data, then the content of
from system failure. the file will be lost.
Manipulation DBMS contains a wide The file system can't efficiently store and
Techniques variety of sophisticated retrieve the data.
techniques to store and
retrieve the data.
Concurrency DBMS takes care of In the File system, concurrent access has
Problems Concurrent access of data many problems like redirecting the file
using some form of while deleting some information or
locking. updating some information.
Where to use Database approach used in File system approach used in large systems
large systems which which interrelate many files.
interrelate many files.
Data Due to the centralization In this, the files and application programs
Redundancy of the database, the are created by different programmers so
and problems of data that there exists a lot of duplication of data
Inconsistency redundancy and which may lead to inconsistency.
5
inconsistency are
controlled.
View of data in DBMS narrate how the data is visualized at each level of data abstraction? Data
abstraction allow developers to keep complex data structures away from the users. The developers
achieve this by hiding the complex data structures through levels of abstraction.
Data Abstraction
Data abstraction is hiding the complex data structure in order to simplify the user’s interface of
the system. It is done because many of the users interacting with the database system are not that
much computer trained to understand the complex data structures of the database system.
To achieve data abstraction, we will discuss a Three-Schema architecture which abstracts the
database at three levels discussed below:
Three-Schema Architecture:
The main objective of this architecture is to have an effective separation between the user
interface and the physical database
The physical or the internal level schema describes how the data is stored in the hardware. It also
describes how the data can be accessed. The physical level shows the data abstraction at the lowest
level and it has complex data structures. Only the database administrator operates at this level.
It is a level above the physical level. Here, the data is stored in the form of the entity set, entities,
their data types, the relationship among the entity sets, user operations performed to retrieve or
modify the data and certain constraints on the data. Well adding constraints to the view of data
adds the security. As users are restricted to access some particular parts of the database.
It is the developer and database administrator who operates at the logical or the conceptual level.
It is the highest level of data abstraction and exhibits only a part of the whole database. It exhibits
the data in which the user is interested. The view level can describe many views of the same data.
Here, the user retrieves the information using different application from the database.
Now, the entity sets Student, Lecturer, Department, Course will be stored in the storage as
the consecutive blocks of the memory location. This is the physical or internal level and is
hidden from the programmers but the database administrator is it aware of it.
At the logical level, the programmers define the entity sets and relationship among these entity sets
using a programming language like SQL. So, the programmers work at the logical level and even
the database administrator also operates at this level.
At the view level, the users have the set of applications which they use to retrieve the data they are
interested in.
Data Independence
Data independence defines the extent to which the data schema can be changed at one level
without modifying the data schema at the next level. Data independence can be classified as shown
below:
Logical Data Independence:
Logical data independence describes the degree up to which the logical or conceptual schema can
be changed without modifying the external schema. Now, a question arises what is the need to
change the data schema at a logical or conceptual level?
Physical Data Independence:
Physical data independence defines the extent up to which the data schema can be changed at the
physical or internal level without modifying the data schema at logical and view level.
Well, the physical schema is changed if we add additional storage to the system or we reorganize
some files to enhance the retrieval speed of the records.
Hierarchical Model
This concept uses a hierarchical tree structure to organise the data. The hierarchy begins at the root,
which contains root data, and then grows into a tree as child nodes are added to the parent node. If
you wish to learn more about the hierarchical model, click here.
Network Model
The main difference between this model and the hierarchical model is that any record can have
several parents in the network model. It uses a graph instead of a hierarchical tree. If you wish to
learn more about the network model, click here.
7
Entity-Relationship Model
The real-world problem is depicted in visual form in this model to make it easier for stakeholders
to comprehend. The ER diagram also makes it very simple for developers to comprehend the
system. If you wish to learn more about the entity-relationship model, click here.
Relational Model
The data in this model is kept in the form of a table that is two-dimensional. All of the data is kept
in the form of rows and columns. Tables are the foundation of a relational paradigm. If you wish to
learn more about the relational model, click here.
management system (DBMS). So, the database languages are used to read, update and store data in
the database.
Database users are categorized based up on their interaction with the database. These are seven
types of database users in DBMS.
1. Database Administrator (DBA): Database Administrator (DBA) is a person/team who
defines the schema and also controls the 3 levels of database. The DBA will then create a
new account id and password for the user if he/she need to access the database. DBA is also
responsible for providing security to the database and he allows only the authorized users to
access/modify the data base. DBA is responsible for the problems such as security breaches
and poor system response time.
DBA also monitors the recovery and backup and provide technical support.
The DBA has a DBA account in the DBMS which called a system or superuser
account.
DBA repairs damage caused due to hardware and/or software failures.
DBA is the one having privileges to perform DCL (Data Control Language)
operations such as GRANT and REVOKE, to allow/restrict a particular user from
accessing the database.
2. Naive / Parametric End Users: Parametric End Users are the unsophisticated who don’t
have any DBMS knowledge but they frequently use the database applications in their daily
life to get the desired results. For examples, Railway’s ticket booking users are naive users.
Clerks in any bank is a naive user because they don’t have any DBMS knowledge but they
still use the database and perform their given task.
3. System Analyst:
System Analyst is a user who analyzes the requirements of parametric end users. They
check whether all the requirements of end users are satisfied.
4. Sophisticated Users: Sophisticated users can be engineers, scientists, business analyst,
who are familiar with the database. They can develop their own database applications
according to their requirement. They don’t write the program code but they interact the
database by writing SQL queries directly through the query processor.
5. Database Designer: Data Base Designers are the users who design the structure of
database which includes tables, indexes, views, triggers, stored procedures and constraints
which are usually enforced before the database is created or populated with data. He/she
controls what data must be stored and how the data items to be related. It is responsibility
of Database Designers to understand the requirements of different user groups and then
create a design which satisfies the need of all the user groups.
6. Application Programmers: Application Programmers also referred as System Analysts or
simply Software Engineers, are the back-end programmers who writes the code for the
application programs. They are the computer professionals. These programs could be
written in Programming languages such as Visual Basic, Developer, C, FORTRAN,
COBOL etc. Application programmers design, debug, test, and maintain set of programs
called “canned transactions” for the Naive (parametric) users in order to interact with
database.
7. Casual Users / Temporary Users: Casual Users are the users who occasionally use/access
the database but each time when they access the database they require the new information,
for example, Middle or higher level manager.
10
STATES OF TRANSACTION
Transactions can be implemented using SQL queries and Server. In the below-given
diagram, you can see how transaction states works.
STATES OF TRANSACTION
Transactions can be implemented using SQL queries and Server. In the below-given
diagram, you can see how transaction states works.
11
Active state
The active state is the first state of every transaction. In this state, the transaction is
being executed.
For example: Insertion or deletion or updating a record is done here. But all the
records are still not saved to the database.
Partially committed
In the partially committed state, a transaction executes its final operation, but the data
is still not saved to the database.
In the total mark calculation example, a final display of the total marks step is
executed in this state.
Committed
A transaction is said to be in a committed state if it executes all its operations successfully. In
this state, all the effects are now permanently saved on the database system.
Failed state
If any of the checks made by the database recovery system fails, then the transaction
is said to be in the failed state.
In the example of total mark calculation, if the database is not able to fire a query to
fetch the marks, then the transaction will fail to execute.
Aborted
o If any of the checks fail and the transaction has reached a failed state then the
database recovery system will make sure that the database is in its previous consistent
state. If not then it will abort or roll back the transaction to bring the database into a
consistent state.
o If the transaction fails in the middle of the transaction then before executing the
transaction, all the executed transactions are rolled back to its consistent state.
o After aborting the transaction, the database recovery module will select one of the two
operations:
Aborted
If any of the checks fail and the transaction has reached a failed state then the
database recovery system will make sure that the database is in its previous consistent
state. If not then it will abort or roll back the transaction to bring the database into a
12
consistent state.
If the transaction fails in the middle of the transaction then before executing the
transaction, all the executed transactions are rolled back to its consistent state.
After aborting the transaction, the database recovery module will select one of the two
operations:
1. Re-start the transaction
2. Kill the transaction
TRANSACTION PROPERTY
The transaction has the four properties. These are used to maintain consistency in a database,
before and after the transaction.
Property of Transaction
1. Atomicity
2. Consistency
3. Isolation
4. Durability
Atomicity
It states that all operations of the transaction take place at once if not, the transaction
is aborted.
There is no midway, i.e., the transaction cannot occur partially. Each transaction is
treated as one unit and either run to completion or is not executed at all.
Atomicity involves the following two operations:
Abort: If a transaction aborts then all the changes made are not visible.
Commit: If a transaction commits then all the changes made are visible.
Consistency
The integrity constraints are maintained so that the database is consistent before and
after the transaction.
o The execution of a transaction will leave a database in either its prior stable state or a
new stable state.
o The consistent property of database states that every transaction sees a consistent
database instance.
o The transaction is used to transform the database from one consistent state to another
consistent state.
Isolation
o It shows that the data which is used at the time of execution of a transaction cannot be
used by the second transaction until the first one is completed.
o In isolation, if the transaction T1 is being executed and using the data item X, then
that data item can't be accessed by any other transaction T2 until the transaction T1
ends.
o The concurrency control subsystem of the DBMS enforced the isolation property.
Durability
o The durability property is used to indicate the performance of the database's
consistent state. It states that the transaction made the permanent changes.
o They cannot be lost by the erroneous operation of a faulty transaction or by the
system failure. When a transaction is completed, then the database reaches a state
known as the consistent state. That consistent state cannot be lost, even in the event of
a system's failure.
o The recovery subsystem of the DBMS has the responsibility of Durability property.
13
DBMS (Database Management System) acts as an interface between the user and the database. The
user requests the DBMS to perform various operations (insert, delete, update and retrieval) on the
database. The components of DBMS perform these requested operations on the database and
provide necessary data to the users. The various components of DBMS are shown below: -
Structure of DBMS
2. DML Compiler and Query optimizer - The DML commands such as insert, update,
delete, retrieve from the application program are sent to the DML compiler for compilation into
object code for database access. The object code is then optimized in the best way to execute a
query by the query optimizer and then send to the data manager.
3. Data Manager - The Data Manager is the central software component of the DBMS also
knows as Database Control System.
A Database store a lot of critical information to access data quickly and securely. Hence it is
important to select a correct Architecture for efficient data management.
Types of DBMS Architecture:
1- Tier Architecture
2- Tier Architecture
3- Tier Architecture
won’t use this architecture they logically go for 2-Tier and 3-Tier Architecture.
Two-tier architecture:
The two-tier architecture is similar to a basic client-server model. The application at the client end
directly communicates with the database at the server side. APIs like ODBC and JDBC are used
for this interaction. The server side is responsible for providing query processing and transaction
management functionalities. On the client side, the user interfaces and application programs are
run. The application on the client side establishes a connection with the server side in order to
communicate with the DBMS.
An advantage of this type is that maintenance and understanding are easier, and compatible with
existing systems. However, this model gives poor performance when there are a large number of
users.
1960s
Computerized databases started in the 1960s, when the use of computers became a more cost-
effective option for private organizations. The history of computers and databases are interlinked.
As prices dropped it became easier to shift data storage and databases to computers.
There were two popular data models in this decade: a network model called CODASYL and a
hierarchical model called IMS. One database system that proved to be a commercial success was
the SABRE system that was used by IBM to help American Airlines manage its reservations data.
1970s
The Introduction of the Relational Database
E.F. Codd published an important paper that served as the introduction of the relational database,
and his ideas changed the way people thought about databases. In his model, the database’s
schema, or logical organization, is disconnected from physical information storage, and this
became the standard principle for database systems.
Two major relational database system prototypes were created between the years 1974 and 1977,
and they were the Ingres, which was developed at UBC, and System R, created at IBM San Jose.
Ingres used a query language known as QUEL, and it led to the creation of systems such as Ingres
Corp., MS SQL Server, Sybase, Wang’s PACE, and Britton-Lee. On the other hand, System R
used the SEQUEL query language, and it contributed to the development of SQL/DS, DB2,
Allbase, Oracle, and Non-Stop SQL. It was also in this decade that Relational Database
Management System, or RDBMS, became a recognized term.
In 1976, new database model called Entity-Relationship, or ER, was proposed by P. Chen this year.
This model made it possible for designers to focus on data application, instead of logical table
structure.
1980s
Structured Query Language, or SQL, became the standard query language, selected by the
American National Standards Institute in 1986 and the International Organization for
Standardization in 1987.
Relational database systems became a commercial success as the rapid increase in computer sales
boosted the database market, and this caused a major decline in the popularity of network and
hierarchical database models. DB2 became the flagship database product for IBM, and the
introduction of the IBM PC resulted in the establishments of many new database companies and
the development of products such as PARADOX, RBASE 5000, RIM, Dbase III and IV, OS/2
Database Manager, and Watcom SQL.
1990s
The 1990s served a pivotal role in the advancement of databases and database software. Similar to
the 1960s, a broader culture shift led to further developments in the industry. After a shakeout,
most of the surviving companies sold complex database products at high prices.
Around this time, new client tools for application development were released, and these included
the Oracle Developer, PowerBuilder, VB, and others. A number of tools for personal productivity,
such as ODBC and Excel/Access, were also developed. Prototypes for Object Database
Management Systems, or ODBMS, were created in the early 1990s.
During the middle of the decade the advent of the Internet led to exponential growth of the
database industry. Average desktop users began to use client-server database systems to access
computer systems that contained legacy data. As more and more users purchased personal
computers and went online, there became a larger need to enhance databases.
Toward the end of the 1990s, increased investment in online businesses resulted in a rise in
demand for Internet database connectors, such as Front Page, Active Server Pages, Java Servelets,
Dream Weaver, ColdFusion, Enterprise Java Beans, and Oracle Developer 2000. The use of CGI,
16
GCC, MySQL, Apache, and other systems brought open source solution to the Internet. With the
increased use of point-of-sale technology, online transaction processing and online analytic
processing began to come of age.
2000s
Although the Internet industry experienced a decline in the early 2000s, database applications
continued to grow. New interactive applications were developed for PDAs, point-of-sale
transactions, and consolidation of vendors. Presently, the three leading database companies in the
western world are Microsoft, IBM, and Oracle.
17
UNIT: 2
Basic concepts
Constraints Keys, design issues
Entity Relationship diagram, Weak entity
sets
Extended E - R features, Design of an E –
R database schema
Reduction of an E – R Schema of tables
The unified modeling language UML
The ER model defines the conceptual view of a database. It works around real-world entities and
the associations among them. At view level, the ER model is considered a good option for
designing databases.
Entity
An entity can be a real-world object, either animate or inanimate, that can be easily identifiable.
For example, in a school database, students, teachers, classes, and courses offered can be
considered as entities. All these entities have some attributes or properties that give them their
identity.
An entity set is a collection of similar types of entities. An entity set may contain entities with
attribute sharing similar values. For example, a Students set may contain all the students of a
school; likewise a Teachers set may contain all the teachers of a school from all faculties. Entity
sets need not be disjoint.
Attributes
Entities are represented by means of their properties, called attributes. All attributes have values.
For example, a student entity may have name, class, and age as attributes.
There exists a domain or range of values that can be assigned to attributes. For example, a student's
name cannot be a numeric value. It has to be alphabetic. A student's age cannot be negative, etc.
Types of Attributes:
Simple attribute − Simple attributes are atomic values, which cannot be divided further.
For example, a student's phone number is an atomic value of 10 digits.
Composite attribute − Composite attributes are made of more than one simple attribute.
For example, a student's complete name may have first_name and last_name.
Derived attribute − Derived attributes are the attributes that do not exist in the physical
database, but their values are derived from other attributes present in the database. For
example, average_salary in a department should not be saved directly in the database,
instead it can be derived. For another example, age can be derived from data_of_birth.
18
Binary = degree 2
Ternary = degree 3
n-ary = degree
Mapping Cardinalities:
Cardinality defines the number of entities in one entity set, which can be associated with the
number of entities of other set via relationship set.
One-to-one − One entity from entity set A can be associated with at most one entity of
entity set B and vice versa.
One-to-many − One entity from entity set A can be associated with more than one entities
of entity set B however an entity from entity set B, can be associated with at most one
entity.
19
Many-to-one − More than one entities from entity set A can be associated with at most one
entity of entity set B, however an entity from entity set B can be associated with more than
one entity from entity set A.
Many-to-many − One entity from A can be associated with more than one entity from B
and vice versa.
Constraints are nothing but the rules that are to be followed while entering data into
columns of the database table
Constraints ensure that data entered by the user into columns must be within the criteria
specified by the condition
For example, if you want to maintain only unique IDs in the employee table or if you want
to enter only age under 18 in the student table etc
We have 5 types of key constraints in DBMS
o NOT NULL: ensures that the specified column doesn’t contain a NULL value.
o UNIQUE : provides a unique/distinct values to specified columns.
o DEFAULT: provides a default value to a column if none is specified.
o CHECK :checks for the predefined conditions before inserting the data inside the
table.
o PRIMARY KEY: it uniquely identifies a row in a table.
o FOREIGN KEY: ensures referential integrity of the relationship
1. Not Null :
20
Null represents a record where data may be missing data or data for that record may be
optional
Once not null is applied to a particular column, you cannot enter null values to that
column and restricted to maintain only some proper value other than null
A not-null constraint cannot be applied at table level
Example
CREATE TABLE Orders (
OrderID int NOT NULL,
OrderNumber int NOT NULL,
PersonID int,
PRIMARY KEY (OrderID),
FOREIGN KEY (PersonID) REFERENCES Persons(PersonID)
);
2. Unique:
Sometimes we need to maintain only unique data in the column of a database table, this is
possible by using a unique constraint
Unique constraint ensures that all values in a column are unique
Example
3. DEFAULT:
Example
Age int,
City varchar(255) DEFAULT 'hyderabad'
);
4. Check:
Suppose in real-time if you want to give access to an application only if the age entered by
the user is greater than 18 this is done at the back-end by using a check constraint
Check constraint ensures that the data entered by the user for that column is within the
range of values or possible values specified.
5. Primary Key:
A primary key is a constraint in a table that uniquely identifies each row record in a database table
by enabling one or more the columns in the table as the primary key.
A particular column is made as a primary key column by using the primary key keyword followed
with the column name
6. Foreign Key:
The foreign key a constraint is a column or list of columns that points to the primary key
The main purpose of the foreign key is only those values are allowed in the present table
Reference Table
Child Table
For example, Suppose we design a school database. In this database, the student will be an entity
with attributes like address, name, id, age, etc. The address can be another entity with attributes
like city, street name, pin code, etc and there will be a relationship between them.
23
Component of ER Diagram
A weak entity set is an entity set that does not contain sufficient attributes to uniquely identify its
entities.
In other words, a primary key does not exist for a weak entity set.
However, it contains a partial key called as a discriminator.
Discriminator can identify a group of entities from the entity set.
Discriminator is represented by underlining with a dashed line.
NOTE-
The combination of discriminator and primary key of the strong entity set makes it possible to
uniquely identify all entities of the weak entity set.
Thus, this combination serves as a primary key for the weak entity set.
Clearly, this primary key is not formed by the weak entity set completely.
24
Symbols Used-
Example-
In this ER diagram,
One strong entity set “Building” and one weak entity set “Apartment” are related to each other.
Strong entity set “Building” has building number as its primary key.
Door number is the discriminator of the weak entity set “Apartment”.
This is because door number alone can not identify an apartment uniquely as there may be
several other buildings having the same door number.
Double line between Apartment and relationship set signifies total participation.
It suggests that each apartment must be present in at least one building.
Single line between Building and relationship set signifies partial participation.
It suggests that there might exist some buildings which has no apartment.
Specialization – The process of designating to sub grouping within an entity set is called
specialization. In above figure, the “person” is distinguish in to whether they are
“employee” or “customer”.
Formally in above figure specialization is depicted by a triangle component labelled (is a), means
the customer is a person.
Sometime this ISA (is a) referred as a superclass-subclass relationship. This is also used to
emphasize on to creating the distinct lower level entity sets.
Generalization – generalization is relationship that exist between higher level entity set
and one or more lower level entity sets. Generalization synthesizes these entity sets into
single entity set.
Higher level and lower level entity sets – This property is created by specialization and
generalization. The attributes of higher level entity sets are inherited by lower level entity
sets.
For example: In above figure “customers” and “employee” inherits the attributes of “person”.
Attribute inheritance: When given entity set is involved as a lower entity set in only one
“ISA” (is a) relationship, it is referred as a single attribute inheritance. If lower entity set is
involved in more than one ISA (is a) relationship, it is referred as a multi attribute
inheritance.
Aggregation: there is a one limitation with E-R model that it cannot express relationships
among relationships. So aggregation is an abstraction through which relationship is treated
as higher level entities.
26
1. Logical Schema
2. Physical Schema
3. View Schema
A database that conforms to an E-R database schema can be represented by a collection of tables.
For each entity set and for each relationship set, there is a unique table. A table is a chart with rows
and columns. The set of all possible rows is the Cartesian product of all columns.
A row is also known as a tuple or a record. A table has an unlimited number of rows.
Each column is also known as a field.
Strong Entity Sets:
It is common practice for the table to have the same name as the entity set. There is one column for
each attribute.
Weak Entity Sets:
There is one column for each attribute, plus the attribute(s) the form the primary key of the strong
entity set that the weak entity set depends upon.
27
Relationship Sets:
We represent a relationship with a table that includes the attributes of each of the primary keys plus
any descriptive attributes (if any).
There is a problem that if one of the entities in the relationship is a weak entity set, there would be
no unique information in the relationship table, and therefore may be omitted.
Another problem can occur if there is an existence dependency. In that case, you can combine the
two tables.
Multivalued Attributes:
When an attribute is multivalued, remove the attribute from the table and create a new table with
the primary key and the attribute, but each value will be a separate row.
Generalization:
Create a table for the higher-level entity set. For each lower-level entity set, create a table with the attributes
for that specialization and include the primary key from the higher-le vel entity set.
Unified Modeling Language (UML) is a general purpose modelling language. The main aim of
UML is to define a standard way to visualize the way a system has been designed. It is quite
similar to blueprints used in other fields of engineering.
UML is not a programming language, it is rather a visual language. We use UML diagrams to
portray the behavior and structure of a system. UML helps software engineers, businessmen
and system architects with modelling, design and analysis. The Object Management Group
(OMG) adopted Unified Modelling Language as a standard in 1997. Its been managed by OMG
ever since. International Organization for Standardization (ISO) published UML as an approved
standard in 2005. UML has been revised over the years and is reviewed periodically. UML is
linked with object oriented design and analysis. UML makes the use of elements and forms
associations between them to form diagrams. Diagrams in UML can be broadly classified as:
1. Structural Diagrams – Capture static aspects or structure of a system. Structural Diagrams
include: Component Diagrams, Object Diagrams, Class Diagrams and Deployment
Diagrams.
2. Behavior Diagrams – Capture dynamic aspects or behavior of the system. Behavior
diagrams include: Use Case Diagrams, State Diagrams, Activity Diagrams and Interaction
Diagrams.
The image below shows the hierarchy of diagrams according to UML 2.2
28
UNIT-4