Chapter 1: Introduction to Distributed Systems A distributed system is a collection of independent computers that appear to users as a single system. It enables resource sharing, scalability, reliability, and fault tolerance, using communication networks
haile468688
5 views
38 slides
Oct 31, 2025
Slide 1 of 38
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
About This Presentation
the first chapter of the distributed system
Size: 1.3 MB
Language: en
Added: Oct 31, 2025
Slides: 38 pages
Slide Content
Chapter One Introduction to Database System 1
Data Handling approaches Roles in Database Design & Development Data and Database Administrator Database Designer Application Programmer End-Users The ANSI-SPARC Architecture Functions of DBMS Data models and conceptual models Database Languages (DDL, DML,DCL) Outline 2
A Database System: an organized collection of data and software used to manage and access that data efficiently It provides a structured way to store, retrieve, and manipulate information, ensuring data integrity, security, and consistency across multiple users and applications Database System = Database+DBMS+Users /application Database a structured collection of related data stored electronically E.g. SMIS 3 Introduction
Data : raw facts such as names, numbers, addresses etc. that are stored in the database Database Management System ( DBMS): is software that allows users to define, create, maintain, and control access to the database E.g. MySQL , Oracle, PostgreSQL, Microsoft SQL Server Database Application : interfaces that allow users to interact with database to preform operations inserting, updating, querying, and deleting data E.g. web applications, desktop software, and mobile apps 4 Introduction…
Data handling: process of collecting, organizing, storing, and analyzing data to make it useful for decision-making and problem-solving There are three main approaches of data handling Manual Approach Data is recorded, stored, and processed manually using paper files or cards Advantage: simple to understand, low cost disadvantage prone to errors and difficult to update not scalable for large amounts of information 5 Data Handling Approach
2. Traditional File( Electronic Data Handling ) Based Approach data is stored in computer files ( e.g.text files, spreadsheets ) Each file is managed by its own program Limitations Data redundancy Lack of data sharing and consistency Hard to maintain and modify Fixed query processing which defined during application development The most significant problem experienced by the traditional file-based of data handling approach is update anomalies 6 Data Handling Approach …
Anomaly : problems or inconsistency which happened during the operations performed on the table There are three types of update anomalies Modification Anomalies: a problem experienced when one or more data value is modified on one application program but not on others containing the same data set Deletion Anomalies : a problem encountered where one record set is deleted from one application but remain untouched in other application programs Insertion Anomalies: a problem encountered where one cannot decide whether the data to be inserted is valid and consistent with other similar data set 7 Data Handling Approach…
3. Database Approach: d ata is stored in a centralized database and managed by a Database Management System(DBMS ). Database is a collection of logically related data where these logically related data comprises entities, attributes, relationships, and business rules of an organization's information Benefits Reduced data redundancy through data integration Easier data sharing among multiple applications Provides data security, consistency, backup, and recovery Supports concurrent access by multiple users . 8 Data Handling Approach…
Limitations and risk of Database Approach High cost ( hardware , software, and training) DBMS design and management are technically complex System failure risk Security threats Specialized skill is required for DBA and data experts Data conversion issues (migration data from old to new) Data corruption (bugs, power failure, system errors) Performance overhead Data Handling Approach… 9
Database Administrator (DBA) Focuses on the technical management and operation of the database system itself Install, configure, and upgrade the DBMS software Create and manage databases, tables, indexes, and views . Control user access and ensure data security . Perform backup and recovery operations Handle data storage, space management, and transaction processing Support application developers in writing efficient queries Roles in Database Design & Development 10
b. Data Administrator (DA): the overall management of data resources in an organization Define data policies, standards, and naming conventions Ensure data consistency , quality , and security across the organization Roles in Database Design & Development 11
2. Database Designer ( DBD) are responsible for: identifying the data to be stored in the database and choosing appropriate structures to represent and store the data . Understanding the user requirement and create a design that meets these requirements The final database design must be capable of supporting the requirements of all user groups There are two distinctions of database designers based on the responsibility Logical and conceptual design Physical design Roles in Database Design & Development 12
Logical and conceptual design focuses on the conceptual and logical structure of the data what data should be stored and how the data elements are related Identify the entities, attributes, and relationships among data items . Develop the Conceptual Data Model (e.g., ER diagram). Define integrity constraints (primary keys, foreign keys, etc.). Physical design focuses on how data is actually stored and accessed on physical devices Decide how tables, indexes, and files are stored on disks Design storage structures ( e.g. B-trees , hash indexes ) Implement security and access control settings Roles in Database Design & Development 13
3. Application Programmer and Systems Analyst Systems Analyst : responsible for studying and analyzing user requirements, designing system specifications , and ensuring the database system meets organizational goals Prepares system flowcharts, data flow diagrams (DFDs), and functional specification Application programmer: writes programs that allow end users to interact with the database through user-friendly applications implement the specification they code, test , debug, document and maintain the application program Determines the interface on how to retrieve, insert, update and delete data in the database. Roles in Database Design & Development 14
4. End Users : are the people whose jobs require access to database for querying , updating , and generating reports There are different group of users in this category Naïve Users : These users make up the majority of database users They regularly use predefined queries and applications developed by programmers They usually fill out forms or use specific screens without writing queries themselves E.g. Bank customers and tellers check account balances and post withdrawals and deposits. Roles in Database Design & Development 15
b. Sophisticated Users They are experienced users who understand the database structure and can write complex SQL queries They often perform data analysis , research , or forecasting E.g. Data analysts, scientists, and business intelligence experts . c . Casual End Users They occasionally access the database but are not familiar with the full structure of the system They use ad hoc queries to retrieve specific information as needed E.g. A manager who occasionally checks sales reports or employee performance data These users can be again classified as Actors on the Scene and Workers Behind the Scene Roles in Database Design & Development 16
Actors On the Scene: Data Administrator Database Administrator Database Designer End Users Workers Behind the Scene DBMS designers and implementers : who design and implement different DBMS software packages(modules ) Tool Developers : experts who develop software packages that facilitates database system designing and use Includes packages for database design, performance monitoring , natural language, prototyping, simulation, and test data generation Roles in Database Design & Development 17
Workers Behind the Scene… Operators and Maintenance Personnel( system administration personnel ) are responsible for the actual running and maintenance of the hardware and software environment for the database system Roles in Database Design & Development 18
Is framework proposed by the American National Standards Institute (ANSI) and Standards Planning and Requirements Committee (SPARC ) in the 1970s defines how a database system should be structured to separate the user’s view , conceptual organization and physical storage of data The goal of three-schema architecture is to separate the user applications from physical database External Level (View Level ) The highest level that defines how individual users view the data Describes only part of the database relevant to a specific user or application Hides other data that is not needed by the user ANSI-SPARC(Three Level Database) Architecture 19
E,g Grade of students and Instructor 2. Conceptual ( Logical Level ) Layer Describes the logical structure of the entire database as a whole Provides a community user view, independent of physical storage details Defines all entities, data types, relationships, and constraints Ensures data integrity and consistency e.g. students and courses 3. Internal() Layer Describes how the data is physically stored in the database Defines how records are stored, ordered, and accessed . Optimizes performance and storage utilization E.g. using B-tree indexes or hash tables to access data efficiently The ANSI-SPARC Architecture … 20
The ANSI-SPARC Architecture … 21
The major objective of ANSI-SPARC architecture is to provide data independence , i.e. upper levels are unaffected by changes to lower levels Data independence is the ability to change the schema at one level of a database system without having to change the schema at the next higher level There are two types of data independence Logical Data Independence Physical Data Independence The ANSI-SPARC Architecture … 22
Logical Data Independence: is the capacity to change the conceptual schema without having to change external schemas( user views ) or application programs E.g adding record type or data item Physical Data Independence: is the capacity to change the internal schema ( physical storage structure ) without having to change the conceptual schema E.g. Move data storage from hard disk to a SSD for faster access The ANSI-SPARC Architecture … 23
The ANSI-SPARC Architecture … 24
DBMS is software that stores, manages, and retrieves data in a structured way It acts as an interface between users/applications and d atabase , ensuring data is organized, secure, and consistent DBMS services Data storage , retrieval and update in the database Transaction support service: ALL or NONE transaction that minimize data inconsistency Concurrency Control Services : access and update the database by different users simultaneously should be implemented correctly Functions of DBMS 25
Recovery Services recovering the database after a failure Security implement Control access and privileges for users and administrators Data Communication Support provide facility to integrate with data transfer software e.g. from remote Integrity Services enforce data correctness, consistency, and business rule data independency minimize impact of database changes on application Utility services Data import/export, Statistical analysis, Index reorganization Functions of DBMS… 26
Data Model: a collection of concepts that can be used to describe the structure of a database( data types, relationships, and constraints) that apply to the data Data model helps to understand the relationship between entities and create the most effective structure to hold data The main purpose of Data Model is to represent the data in an understandable way There are a different models for data. Some most well-known models Hierarchical Model Network Model Relational Data Model Data models and conceptual models 27
a. Hierarchical Model organizes data in a hierarchical tree structure The hierarchy begins at the root, which contains root data It expands into a tree adding child nodes to the parent node This model can easily represent some real-world relationships there is a one-to-many relationship between data types Data models and conceptual models 28
Hierarchical Data Model … ADVANTAGES DISADVANTAGES Data models… It is very easy and quick to navigate through a tree-like structure Changes in the parent node are automatically reflected in child nodes so data integrity is maintained . Easy to find the difference Complex relationships cannot be supported It does not support more than one parent of the child Node. If there is a complex relationship, where a child Node requires two parent nodes, it cannot be represented with this model. The child node will be deleted automatically if a parent node has been deleted 29
b . Network Model Data is organized as records and sets (links between records ). Supports complex relationships between entities This model can manage both one-to-one and many-to-many relationships Efficient for navigational access to data Data models and conceptual models 30
Network Data Model… ADVANTAGES of Network Data Model: DISADVANTAGES of Network Data Model Data models and conceptual models … Data can be accessed more quickly than the hierarchical model Allows linking any record to multiple other records Especially suitable for databases with highly connected data The system can become more complicated as more relationships are needed to be managed Any type of change, such as updating, deletion, or insertion, is extremely complex 31
c. Relational Data Model Developed by Dr. Edgar Frank Codd in 1970 (famous paper, 'A Relational Model for Large Shared Data Banks ') The relational model is the most popular model . It is a model where the information is stored as two-dimensional tables . All information is stored in rows and columns . The foundation of a model that is relational is tables Therefore the tables are known as relations within the model. Data models and conceptual models 32
c. Relational Data Model… Each row within the table is known as the tuple Field/attribute : Attributes are the property that defines the table or relationship In a Relational database matches information from a field in one table with information in a corresponding field of another table to produce a third table that combines requested data from both tables Data models and conceptual models Alternative terminologies Relation Table File Tuple Row Record Attribute Column Field 33
Conceptual models: is a high-level representation of the database that shows what data is stored and how it is related, independent of physical storage Focuses on entities , attributes , and relationships rather than implementation details . Components of conceptual model Entities: r eal-world objects (e.g. Student, Course ) Attributes : properties of entities (e.g., Name, ID ) Relationships : how entities are connected (e.g., Student ENROLLS in Course) Data models and conceptual models 34
Data Definition Language (DDL ): Allows DBA or user to describe and name entitles, attributes and relationships required for the application. Specification notation for defining the database schema E.g. CREATE, DROP,ALTER, TRUNCATE, REMANE etc. Data Manipulation Language (DML) Provides basic data manipulation operations on data held in the database a Language for accessing and manipulating data organized by appropriate data model It is also known as query language e.g. SELECT, INSERT, UPDATE, DELETE etc Database Languages 35
Data Manipulation Language (DML ) … Procedural DML : user specifies what data is required and how to get the data. Non-Procedural DML : user specifies what data is required but not how it is to be retrieved. Data Control Language (DCL) Allows a DBA to define access control and privileges for users. It is a mechanism for implementing security at a database object level Uses the Grant and Revoke SQL Statements SQL is the most widely used non-procedural query language Database Languages 36
Fourth Generation Language (4GL) Query Languages Forms Generators Report Generators Graphics Generators Application Generators Database Languages 37