Database Management System Overview
Database Management System Overview
INTRODUCTIONO ............................................................................................................................................ 2
GENERAL OBJECTIVE.................................................................................................................................. 3
Specific ObjectivesS ..................................................................................................................... 3
1. BASE OF DATA............................................................................................................................... 4
1.1. ADVANTAGES DATABASE............................................................................................ 4
2. SYSTEM ON DATABASE MANAGEMENT............................................................. 6
2.1. DATA............................................................................................................................................. 6
2.2. ARCHITECTURE DATABASE SYSTEMS......................................................... 6
3. O ENTITY-RELATIONSHIP MODEL.............................................................................. 7
3.1. ENTITIES AND ENTITY SETS ............................................................................. 7
3.2. ATTRIBUTES AND CONTROL OF VALUES.................................................................................... 8
3.3. RELATIONSHIP................................................................................................................... 9
3.4. O EXTENDED ENTITY-RELATIONSHIP MODEL (EER)..................................... 10
3.5. O RELAIONAL MODELL ......................................................................................................... 11
3.6. O STRUCTURAL ASPECTL ........................................................................................................ 11
3.7. The ASPECT OF INTEGRITY................................................................................................. 12
4. O SQL STANDARD............................................................................................................................... 15
4.1. LANGUAGE DEFINITION OF DATA............................................................................... 15
4.2. LANGUAGE ON DATA MANIPULATION....................................................................... 15
4.3. TABLES....................................................................................................................................... 16
4.4. CONSULTATIONS ................................................................................................................................. 16
5. CONCLUSION .................................................................................................................................... 17
6. REFERENCES.................................................................................................................................. 18
INTRODUCTION
Databases are increasingly present in our daily lives, given that most of the
The activities we carry out involve, directly or indirectly, the use of a database. In light of
thus, we will present in the following sections an introduction to the fundamental concepts of base of
data. Considering that the database is mostly still relational, this
work will highlight them. Thus, the first chapter defines a database and also discusses the
advantages arising from this approach. The second chapter defines database system, thus
briefly discusses each element that composes it. The third chapter addresses the
Entity-Relationship model, as well as the corresponding diagramming technique, which is
used to model database. The fourth chapter contains a report on the SQL standard,
language used to structure and manipulate relational databases.
2
GENERAL OBJECTIVE
Analyze the functionalities and importance of the database
SPECIFIC OBJECTIVES
Analyze the types of databases
Analyze the data modeling
Advantages of the database
Analyze the database management systems
Analyze the database objects
3
DATABASE
According to DATE (2004, p. 10), 'A database is a collection of persistent data, used
through the application systems of a certain company." In other words, a database
it is a place where data needed for the maintenance of the activities of a certain
organization, with this repository being the data source for current applications and those that will come
to exist.
4
data files without modifying the respective application program. Databases,
however, they allow for data independence, as they enable data abstraction (which
It will be discussed later.
5
2. DATABASE MANAGEMENT SYSTEM
According to DATE (2004, p. 6), a database management system is 'a system
computerized whose general purpose is to store information and allow users
search and update this information when requested." For the author, a bank system of
data consists of data, hardware, software, and users.
[Link]
SETZER and CORRÊA DA SILVA (2005, p. 2) define data as a symbolic representation.
(that is, made through symbols), quantified or quantifiable.” Complementing, ELMASRI
According to NAVATHE (2011, p. 3), they state that data are 'known facts that can be recorded and'
has implicit meaning." In this way, an employee's registration number is a piece of data,
because for the company it is a known fact, it contains semantics, it is represented by symbols
(digits from 0 to 9 - base 10 number system, therefore it is quantified) being, therefore, liable
of registration
High-level or conceptual data model: it is the closest to the end user. Entities,
attributes and relationships are some of the concepts used. An example of this model
It is the Entity-Relationship Model that will be discussed later.
6
Representative or implementation data models: Relational Data Models,
Hierarchical and Network are examples of this model. Here the data is shown using
record structure.
Low-level or physical data model: describes the data of the previous model for
storage on the computer. It deals, for example, with the format of records and the
ways to access this data.
7
According to SETZER and CORRÊA DA SILVA (2005, p. 22), a set of entities is 'a collection
of entities that have similar characteristics, that is, of beings in the same category.
the set of entities Servers represents the collection of all servers that work
in that institution. And the set of entities Campi refers to the set of all units.
of teaching that body. A set of entities is represented in the E-R model by a
rectangle.
8
Stored or Derived Regarding the derived attribute SILBERSCHATZ, KORTH and
SUDARSHAN (1999, p. 24) defines that 'the value of this type of attribute can be derived
of other attributes or entities related to it." The attribute Data_Exercicio that
The date of commencement of effective exercise of each server is an example of an attribute.
stored. The attribute Contribution_Time represents the total length of service
provided to the institution is a derived attribute, because it can be obtained from the value of
Exercise data and by the current date.
Nulls 'A null attribute is used when an entity does not have a value for a certain
attribute" (SILBERSCHATZ; KORTH; SUDARSHAN, 1999, p. 24). The attribute
The Reservist Number of the group of entities Servers is a null attribute, as it does not
applies to all entities (servers do not have Military Service Card).
Keys or Determinants SETZER and CORRÊA DA SILVA (2005, p. 31) define that
Given a set of entities, there are no two entities in that set with the same value.
for that attribute. In other words, given a value for that attribute, that value
determine to which entity it is associated.
3.3. RELATIONSHIPS
A relationship is an association between one or several entities.
KORTH; SUDARSHAN, 1999, p. 24). Illustrating, when we refer to the place where each
the server performs its activities - its assignment - this data does not refer only to Servers
and not solely to Campi, but to both. This element is dependent on one and the other entity
it is represented in the ERD by what is called a relationship. So, in our example, we say
the entities in Servers are associated with the entities in Campuses through the relationship
Grouping. "A set of relationships is a set of relationships of the same type."
(SILBERSCHATZ; KORTH; SUDARSHAN, 1999, p. 25). In the E-R model, sets of
relationships are represented by diamonds.
9
Fig.1 graphical representation of relationship
We should read the previous diagram as follows: Servers are stationed at Campuses,
left to right; and Campié occupancy of Servers, from right to left. "The entities
Those involved in a certain relationship are said to be participants in that relationship.
The number of participants in a certain relationship is called the degree of that relationship.
(DATE, 2004, p. 357). Thus, in the previous example there is a relationship of degree two.
(also known as binary relationship), as there are two sets of entities
participants: Servers and Campuses. Relationships, similarly to entities, can have
descriptive attributes (SILBERSCHATZ; KORTH; SUDARSHAN, 1999, p. 25). For example,
let us suppose that the servers may, at the interest of public administration, be removed from a
work pole to another and that it is necessary to store in a database the history of the
removals made. So, to the relationship Allocation, which associates Servers and Campuses, adds
the attribute Start_Date which will represent the employee's admission date in a given campus.
In this way, we will record the server's movement in each of the campuses in which it
come to work.
10
3.5.O RELATIONAL MODEL
The Relational Model (RM) is a representative (or implementation) data model that was
proposed by Ted Codd, in 1970. The model is based on concepts from mathematics–theory
two sets and predicate logic. The first commercial systems based on MR were
made available in 1980 and since then it has been implemented in many systems, such
like Access, Oracle, MySql, among others (ELMASRI; NAVATHE, 2011, p. 38). For DATE
(2004, p. 67), the relational model refers to 'three main aspects of data: the structure of
data, data integrity, and data manipulation.
The set of values that each attribute can take is called a domain (SILBERSCHATZ;
KORTH; SUDARSHAN, 1999, p. 62). Let Dn, where D is the domain of a certain attribute and n
the position of the attribute in the relation and considering the relation Positions (figure 3), it is known that D1 is
domain of the attribute Code, as it represents the set of all possible job codes.
D2 is the domain of Denomination, as it denotes the set of all job titles.
D3 is the domain of Class, as it represents the set of all job classes, and so on.
in front of. According to SILBERSCHATZ, KORTH, and SUDARSHAN (1999, p. 62), a relation is
11
mathematically defined as a subset of the Cartesian product of a list of domains.
In this way, the relation Positions is denoted by D1xD2xD3xD4, that is, Positions is a subset
of the set of all possible combinations of values. A relation scheme (or scheme of
relation) is used to describe a relationship. A schema is indicated by R(A1, A2, c, An), where
R is the name of the relation and An are its attributes (ELMASRI; NAVATHE, 2011, p. 40). For example,
Positions (Code, Denomination, Class, Category) represent the schema of the Positions relation.
The number of attributes in a relational schema is called degree or arity (ELMASRI;
NAVATHE, 2011, p. 40). Positions, for example, is a relationship of degree three. An instance of
A relation (or state of relation) is a set of tuples – their values at a given moment. The state
r of the R schema, denoted by r(R), is a set of tuples r={t1, t2,..., tn}, where each tuple t is
formed by a list of values t=(v1, v2, c, vn), where each value vi is in the domain of
respective attribute Ai (ELMASRI; NAVATHE, 2011, p. 40). For example, the instance of
The diagram of the relationship Positions (figure 13) is composed of five tuples, each tuple is a list of four.
valores (por exemplo, na primeira tupla temos os seguintes valores: 701001, Administrador, E,
Technical-Administrative), with each value being an element of the domain of the corresponding attribute
(701001 is in the domain of the Code attribute, Administrator is in the domain of Denomination, and
is in the domain of Class and Technical Administrative is in the domain of Category.
12
2.) Irreducibility: establishes that there should not be anything in the set of attributes called key
a subset that has the property of uniqueness. In other words, besides following
the first rule, the key must be a minimum set of attributes. For example, the
set {Code, Denomination} is not a key, because although it satisfies the first
the rule ends up breaking the second–{Code} and {Denomination}, taken separately,
uniquely identifies each tuple in the Positions relation. The set {Code} is a
example of a key, as it simultaneously meets the two conditions above. A relationship
can have more than one key, each of which is called a candidate key
(ELMASRI; NAVATHE, 2011, p. 45). {Code} and {Denomination}, for example, are
candidate keys. The candidate key used to identify tuples in a given relation
is called the primary key. The other candidate keys of this relation are called keys.
unique. A primary key is indicated by underlining the attributes in the relation schema
they compose (ELMASRI; NAVATHE, 2011, p. 45). Illustrating, the schema of the relationship
we will discuss the concepts of foreign key and referential integrity through a
example.
Considering the representation above, we interpret from the Entity-Relationship Diagram (figure
4a) that each entity in the set of entities Servers occupies at least one and at most one position.
13
Meanwhile, a position can be occupied by none or many employees. Mapping this situation
for the Relational Model, the following relation schemas are obtained: Positions(Code,
Denomination
Consequently, there will be two relationships according to figure 4b. Note that the relationship
Occupation between the sets of entities Servers and Positions occurs in the Relational Model.
(figure 4b) through the transposition of the Attribute Code of Positions for Servers. This attribute
transposed in Servers (it has as origin the relation Positions and as destination the relation Servers)
it is called a foreign key. A tuple in Servers refers to a tuple in Positions,
since this reference is made through the value contained in the attribute Code. It is called
referential integrity is the rule that the value contained in the foreign key of Servers must
correspond to a primary key value in Positions. In other words, the integrity
referential is the restriction that 'the database cannot contain any key values'
"non-corresponding foreigners" (DATE, 2004, p. 237).
14
4. THE SQL STANDARD
Structured Query Language (SQL) was created by IBM.
Research, in the early 1970s, for the prototype of a database system called
System R (DATE, 2004, p. 71). Based on the languages of Algebra and Relational Calculus, and
initially named SEQUEL (Structured English QUEry Language), SQL today is the
standard language for Relational Database Management Systems (RDBMS), being
more intelligible than their native languages – considered too technical for the user
SQL is standardized by the American National Standards
Institute (ANSI) and by the International Standards Organization (ISO), jointly. The first
The standard version, called SQL-86 (or SQL1), was released in 1986 and has been since then
updated–SQL-92 (or SQL2), SQL:1999 (or SQL3), SQL:2003, SQL:2006 and, furthermore, another one
the update occurred in 2008 (ELMASRI; NAVATHE, 2011, p. 57). Although known as
a 'query language', SQL also offers features to define the structure of the data,
update–include, exclude and modify–data, specify integrity constraints and other features
but (SILBERSCHATZ; KORTH; SUDARSHAN, 1999, p. 109). According to DATE (2004,
p. 85), SQL has, among others, the following components: Data Definition Language (DDL)
Data Definition Language and Data Manipulation Language (DML) or Language of
Data Manipulation.
15
[Link]
Tables are elements made up of columns and rows, where each column corresponds to a field,
And each line is a record. "A column is defined by its name, by the type of data it can
receive and put a comment. The comment is optional" (SETZER; CORRÊA DA SILVA, 2005,
A table can be created in several ways, including: in Design Mode, using
graphical interface, as shown in figure 15. Item 1 is the name of the table; 2 is where we specify the name.
in the column; in 3 we define the type of data that will be stored; in 4 we optionally put,
a description of the content that the column will store; 5 is where we define the properties of
field, such as: size, default value, required (whether it accepts null values or not), between
others; and 6 indicates that the field is a primary key.
4.4. CONSULTATIONS
A query, for Access, is merely a stored SQL expression for later use
CARVALHO (2006, p. 455). According to SETZER and CORRÊA DA SILVA (2005, p. 229), Access
enables the creation of two types of queries: selection and action. The first type allows for retrieval
database data. The second type implements commands for updating-inserting,
exclusion and change - in the database. Considering these types, the following can be found in Access.
queries:
Selection: is based on the SQL select instruction and is used to select fields and records.
the tables of the database;
Increment: originates from the insert into instruction and is used to add records to the tables;
Exclusion: built from the delete instruction, it is used to delete records from
database tables;
Update: it is based on the update instruction and allows changing the values of the fields in a
table
Create Table: contains the create table instruction and allows the creation of a table in the database
of data.
16
5. CONCLUSION
The database approach presents advantages when compared to processing
traditional files, among the benefits are independence, integrity, and consistency of
data, as well as redundancy control. A database schema relates to
database structure. Schemas can be described through data models. From
just like application software, a database is developed through design,
given that this includes several stages. The conceptual project deserves to be highlighted, in which one
uses the Entity-Relationship Model to describe data and its semantics; and the project
logical, which is the mapping of the conceptual model to the data model of the DBMS that will be
adopted. Even today, most databases are relational, therefore, it is used in this
conversion of the Relational Model.
17
6. REFERENCES
SILBERSCHATZ, Abraham; KORTH, Henry F.; SUDARSHAN, S..BANKING SYSTEM
OF DATA. 3rd ed. São Paulo: Makron Books, 1999.
SETZER, Valdemar W.; SILVA, Flávio Soares Corrêa da. DATABASES: LEARN
WHAT ARE, IMPROVE YOUR KNOWLEDGE, BUILD YOURS. São Paulo:
Edgard Blücher, 2005.
18