Database Management Systems (DBMSs), Study notes of Database Management Systems (DBMS)

An overview of database management systems (dbmss), their definition, historical context, and evolution. It discusses the role of dbmss in information systems, the concept of data independence, and the dik(w) pyramid. The document also covers data models and languages, including the relational model, entity-relationship model, and object-oriented model. The brief history of dbmss is also outlined, highlighting the emergence of commercial systems and the impact of technologies like xml and the semantic web.

Typology: Study notes

2018/2019

Uploaded on 03/29/2024

nizam-muratov
nizam-muratov 🇺🇿

1 document

1 / 35

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Database management:
Chapter 1: Database management system (DBMS):
1. Definition of DBMSs
Definition: A database management system (DBMS) is a collection of interrelated data (information) about
a particular enterprise together with a set of programs to access those data
So:
Collection of interrelated data
Set of programs to access the data
A DBMS provide environment that is both convenient and efficient to use
Organizational context for using database systems:
Historically, ISs dominated by file systems in the 1960s
Since the early 1970s organizations have gradually moved to database management systems
Created the position of database administrator (DBA) and database administration departments
Database systems are integral components in computer-based information systems
Database systems are distributed over multiple computer systems
Better local control and fast local processing
Information systems (ISs):
Definition: An information system includes all resources involved in collection, management, use, and
dissemination of information within the organization - Определение: Информационная система
включает в себя все ресурсы, участвующие в сборе, управлении, использовании и распространении
информации в организации – such resources can be any software, hardware for collection, management,
use and dissemination within the organization, in next text these resources are clarified
In a computerized environment, these resources include data itself, the DBMS software, the computer
system hardware/software and storage media, the personnel who use and manage the data (DBA, user,
technical staff and so on), the application programs (software) that accesses and updates the data, and
the programmers who develop these applications and “transactions- В компьютеризированной среде
эти ресурсы включают в себя сами данные, программное обеспечение СУБД,
аппаратное/программное обеспечение компьютерной системы и носители информации,
персонал, который использует данные и управляет ими (администратор баз данных,
пользователь, технический персонал и т. д.), прикладные программы (программное обеспечение),
которые получают доступ к данным и обновляют их, а также программисты, которые
разрабатывают эти приложения и «транзакции».
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23

Partial preview of the text

Download Database Management Systems (DBMSs) and more Study notes Database Management Systems (DBMS) in PDF only on Docsity!

Database management:

Chapter 1: Database management system (DBMS):

1. Definition of DBMSs

Definition: A database management system (DBMS) is a collection of interrelated data (information) about a particular enterprise together with a set of programs to access those data So:  Collection of interrelated data  Set of programs to access the data A DBMS provide environment that is both convenient and efficient to use Organizational context for using database systems:  Historically, ISs dominated by file systems in the 1960s  Since the early 1970s organizations have gradually moved to database management systems  Created the position of database administrator (DBA) and database administration departments Database systems are integral components in computer-based information systems Database systems are distributed over multiple computer systems  Better local control and fast local processing

Information systems (ISs):

Definition: An information system includes all resources involved in collection, management, use, and dissemination of information within the organization - Определение: Информационная система включает в себя все ресурсы, участвующие в сборе, управлении, использовании и распространении информации в организации – such resources can be any software, hardware for collection, management, use and dissemination within the organization, in next text these resources are clarified In a computerized environment, these resources include data itself, the DBMS software, the computer system hardware/software and storage media, the personnel who use and manage the data (DBA, user, technical staff and so on), the application programs (software) that accesses and updates the data, and the programmers who develop these applications and “transactions- В компьютеризированной среде эти ресурсы включают в себя сами данные, программное обеспечение СУБД, аппаратное/программное обеспечение компьютерной системы и носители информации, персонал, который использует данные и управляет ими (администратор баз данных, пользователь, технический персонал и т. д.), прикладные программы (программное обеспечение), которые получают доступ к данным и обновляют их, а также программисты, которые разрабатывают эти приложения и «транзакции».

2. Users of DBMS A lot of graphs, not so important 3. DBMSs application and purposes Database applications:  Banking: transactions  Airlines: reservations, schedules,  Universities: registration, grades  Sales: customer, products, purchases  Online retailers: order tracking, customized recommendations  Manufacturing: production, inventory, orders, supply chain  Human resources: employee records, salaries, tax, deductions Greatly influenced by underlying computer system on which database is running: - Большое влияние оказывает базовая компьютерная система, на которой работает база данных:  Centralized  Client-server

In the early days, database applications were built directly on top of file systems (O. Ss)

Drawbacks of using file systems

Data redundancy and inconsistency - Избыточность и несогласованность данных  Multiple file formats, duplication of information in different files Difficulty in accessing data (query processing)  Need to write a new application program to carry out each new task over available data  Example: Poor security of “search” in PCs; you can access by “keyword” only: all docs with that keyword (and using additional keyword could not be satisfactory for certain tasks) - Пример: Плохая безопасность «поиска» в ПК; Вы можете получить доступ только по «ключевому слову»: все документы с этим ключевым словом (и использование дополнительного ключевого слова может быть неудовлетворительным для определенных задач) There is explanation of chat GPT: Конечно, давайте рассмотрим трудности в доступе к данным с точки зрения файловой системы:

1. Фрагментация файлов : со временем файлы на накопителе могут разбиваться на фрагменты, что означает, что части файла хранятся в разных физических местах на диске. Доступ к фрагментированным данным может быть медленнее, потому что головка для чтения/записи диска должна перемещаться для сборки всех частей файла. 2. Коррупция файлов : если файл становится поврежденным из-за ошибок диска, внезапного отключения питания или программных ошибок, его содержимое может быть сложно доступным. Файловая система может не суметь правильно интерпретировать данные. 3. Ошибки на диске : Физические проблемы на накопителе, такие как плохие секторы на жестком диске или поврежденные секторы на твердотельном накопителе, могут вызвать трудности в доступе к данным. Файловая система может столкнуться с ошибками при попытке чтения или записи в эти поврежденные области. 4. Ограничения разрешений : Файловая система регулирует разрешения, которые контролируют, кто может получить доступ, изменять или удалять файлы. Неправильные настройки разрешений могут привести к отказу в доступе или ограниченному доступу к данным. 5. Ошибки файловой системы : Ошибки в самой структуре файловой системы могут затруднить доступ к данным. Эти ошибки могут возникнуть из-за проблем, таких как внезапные сбои системы, неправильное выключение или ошибки программного обеспечения. 6. Проблемы с местом на диске : если место на диске почти закончилось, это может привести к проблемам с доступом к данным. Вы можете не иметь возможности сохранять новые файлы или получать доступ к существующим, если свободного места не хватает. 7. Проблемы с структурой каталогов : Файловая система использует структуру каталогов для организации файлов. Если эта структура становится беспорядочной, поиск и доступ к определенным файлам может стать сложным.

Эти трудности, связанные с файловой системой, могут затруднить эффективный доступ к данным, хранящимся на вашем компьютере или устройствах хранения. Поддержание здоровой файловой системы, создание резервных копий и периодическая проверка на ошибки могут помочь смягчить эти проблемы. Data integration problem: Data isolation:  Multiple files and formats; no links among files Integrity problems:  Hard to add new constraints or change existing ones (numerical constraints in MS Excel) Atomicity of updates: - Атомарность обновлений  Failures may leave database in an inconsistent state with partial updates carried out - Сбои могут привести к тому, что база данных останется в несогласованном состоянии с выполнением частичных обновлений: if you make update of software you need to transfer all files with data, and some data in them can stay old or maybe will broke, so it leads to difficulties Concurrent access by multiple users - Одновременный доступ нескольких пользователей  Concurrent access needed for performance - Одновременный доступ, необходимый для повышения производительности  Uncontrolled concurrent accesses can lead inconsistencies - Неконтролируемый одновременный доступ может привести к несоответствиям  Example: Two people reading a balance and updating it by withdrawing money at the same time - Пример: два человека читают баланс и обновляют его, снимая деньги в разумное время. Security problems:  Hard to provide user access to some, but not all, data  Example: Password on acrobat Reader for PDFs is for all the content, not some of it

5. The DBMS approach Database is the sum of interrelated data and a set of programs A purpose of a database (management) system is to provide users with an abstract view of data View of data A database (management) system is a “sum” ofInterrelated data Set of programs: that allow users to access and modify (conveniently, efficiently) those data Data divided on 3 levels: 1. View level 2. Logical or conceptual level

Instance – the content of the database at a particular point in timeAnalogous to the value of variable

6. Data in relation: The DIK(W) Pyramid

Data

Definition (Webster): A collection of facts from which conclusions may be drown Factual information output by a device Useful relevant or redundant ‘information’ which must be processed to be meaningful - Полезная, релевантная или избыточная «информация», которая должна быть обработана, чтобы быть значимой Used as basis for reasoning, discussion or calculation Definition: Any ‘thing’ in input of a processing system that must be processed somewhat to be meaningful In short: Everything that is given

Information

Data is not information Information is content Information is data which possesses a context, relevance and purpose - Информация - это данные, которые обладают контекстом, актуальностью и целью Information is data in relation - Информация - это данные в отношении

Logical level or data to information

Physical level: describes how a record is physically stored Logical level: describes what data are stored in database, and the relationships among the data View level: application programs hide details of data types. Views can also hide information (such as an employee salary or student’s grade) security/privacy purposes

Knowledge

The sum what is known, the body of truth, information, and principles acquired by human kind Knowledge = information in flux (relation) A “statement” that a class is in relation with other classes (IT view) - «Утверждение» о том, что класс связан с другими классами (ИТ-представление) An ontology, a classification, a knowledge base, a database that implies a set of “statements” - Онтология, классификация, база знаний, база данных, подразумевающая набор «утверждений»

7. Data models and languages

Data models

Definition: A collection of conceptual tools for describing:Data and data relationshipsData semantics - meaningData constraints (consistency, duplication, etc.) Relational model (we will learn it in the second part of this semester) Entity-Relationship data model (mainly for DB design, what we will do in the first part of this semester) Object-based data model (Object oriented and object relational) Semi structured data model (XML/RDF/JSON) Other older models:  Network model/Hierarchical model/NoSQL and so on Database systems provide a set of linguistic tools to specify everything about the data it deals with:Data-Definition Language (DDL): To specify the (logical, physical) schemaData-Manipulation Language (DML): To specify the operations to manage the (instances of) data and so on Querying information Inserting new data Deleting existing data Modifying existing

8. Brief history of DBMSs

Chapter 2: Database management system (DBMS):

1. Principles of Software Engineering

 More than 60% of the

IS software Development Process

Fails for poor analysis

 30% of overall cost of IS software Development Process have to be for the Analysis

Principles of software before engineering

Software lifecycle divides on two types: macro lifecycle and micro life cycle Macro life cycle – good example can be messenger like telegram, a lot of people use it every day and of course this app need in maintenance such as correcting bugs, mistakes if it is needed, provide good community services, when users have problems, thanks to this maintenance people will use it for a long time. Development is another important stage, creators in this stage adding in their app something new, and users can enjoy with something new, and see how particular app becomes everyday better and better What about micro life cycle? It has next stages:

  1. Development
  2. Requirement analysis
  3. Design
  4. Implementation
  5. Testing Let’s consider all of them one by one 2. Data requirements

Elicitations and analysis

1: Initial requirements are likely to be informal, incomplete, inconsistent, and partially incorrect - Первоначальные требования, скорее всего, будут неформальными, неполными, непоследовательными и частично неправильными 2: Time-consuming, but it’s a crucial phase to the success of the database systems

Data modeling in organizations

 requirements analysis is what software is to do  design is how the software will do it 4.Implementation Create software system from design:  programming (write the code – choose the language)create a data file (database) Here we have software analysis versus programmers  software analysis involved with requirements analysis and design stepsprogrammers involved with implementation and testing steps At the end of this stage, you are expected to deliver:  the source code of all systemdocument of the functionalities (user’s manual)document on some preliminary testing - документ о предварительном тестировании 5.Testing Testing is not only the process of debugging Strictly related to requirements specification: Does the software do what expected from requirement analysis? Intermediate step in the entire development process should be “tested” for accuracy Important segment in the overall struggle for software Quality Assurance - Важный сегмент в общей борьбе за обеспечение качества программного обеспечения, testing is important step in whole micro lifecycle to provide good quality of work of software Types of tests  Defect test (during the implementation)Unit test (after the implementation)Integration testSystem test – validation testing (to confirm requirements) - Системный тест – валидационное тестирование (для подтверждения требований)α-test: test of software inside by user inside the factoryβ-test: test of software outside by user outside the factory Methodologies Define the “method”, that is, order and interaction among the phases of the System (Software) Development Process Several methodologies or “models”:  Waterfall  Incremental - Добавочного  Iterative - Повторяющийся

 Open-source: incremental/iterative  Extreme programming (XP model) Waterfall model: We know about this method Incremental/iterative models  Based on principle of spiral  Desired software system is constructed by increments – the first being a simplified version of the final product with limited functionality  Once version has been tested and validated (checked) (Проверки) by the customer, more features are added and tested again Chapter 3: Database design: The E-R data model

1. Conceptual database design

Main phases:

An entity is a ‘thing’ or ‘object’ that exists and is distinguishable from other things and objects

Example: a person, company, event, plant and etc.

An entity set (type) is a set of entities of same type share the same properties (attributes)

Example: set of persons, companies, trees, holidays

The extension (расширение) of an entity set is the actual collection of entities belonging to the

entity set

Example: actual instructions from the extension of the entity set instructor

Entity sets (types) – attributes

An entity set (type) is defined by a unique name and a set of attributes, descriptive properties

possessed (have all members) by all members of the set - Набор сущностей (тип) определяется

уникальным именем и набором атрибутов, описательных свойств, которыми обладают

(имеют все члены) все члены множества

What attributes to capture in the database is basically a business-based design decision - То, какие

атрибуты следует зафиксировать в базе данных, в основном является бизнес-решением

по проектированию

Attributes have a value (instance of the attribute)

A subset of attributes forms a primary key of the entity set and uniquely identifies an entity in

the set

Entity sets: Diagramming

 Entity sets represented by rectangles

 Attributes listed inside entity rectangle

 Underline indicates primary key attributes

More on attributes

An attributes domain (area) is the set of acceptable values for the attribute

Attribute types:

 Simple

 Composite

 Single-valued

 Multivalued

 Derived

Simple or key it is attribute that can’t be divided on components, or have more than one value…(it

is usually)

Composite it is attribute that can be divided on components (address can be divided-on street, city,

state and so on)

Multivalued it is attribute that can have more than one value (for example one person can have

two or more phone numbers)

Derived it is attribute that change over a period of time (like your age, year to tear it change, it also

changes in database)

Relationships sets (Types)

A relationship is an association among entities

A relationship set R is a relation among more than two entities, each taken from entity sets where

is the relationship R (two people are related with two advisors)

The degree of a relationship set R is the number of entity sets Ei that participate R

Relationship sets – attributes

Also, relationship sets can have some attributes (like data of registration of student in a class)

Relationship sets: diagramming

Diamonds represents relationship sets

Example with attribute:

Ternary relationship sets are represented this way - Множества троичных отношений

представляются таким образом