SlideShare a Scribd company logo
 
Topics for Today Data Abstraction Data Independence  Data Modeling
Data Abstraction Why it is Important? How it is provided by a DBMS? 3 levels of abstraction Physical or Internal Level Logical Level View or External Level
Data Independence What is Data Independence? Why it is Important? How it is provided by a DBMS? Types of Independence Physical Data Independence Logical Data Independence
Data Modeling What is Data Modeling? An integrated collection of concepts for describing & manipulating data, relationships between data, & constraints on the data in an organization Used for defining Database Schemas Databases have several schemas, partitioned according to levels of abstraction Schema Levels Physical Schema Conceptual/Logical Schema Sub-schemas or external schemas
Popular Data Models Entity-Relationship Model Relational Model Hierarchical Model Network Model Inverted File Model Object-Oriented Model Object-Relational Model
Data Abstraction Major aim of a DBMS is to provide users with an abstract view of data Hides certain details of how the data are stored & maintained DBMS must retrieve data efficiently Need for efficiency has led designers to use complex data structures to represent the data in the database Most DB users are not computer trained, developers hide complexity through several levels of abstraction to simplify user’s interaction with the systems
3 Levels of Abstraction Physical or Internal Level Lowest level of abstraction describes how data are actually stored Describes complex low-level data structures in detail Logical or Conceptual Level Describes what data are stored in the DB & what relationships exist among those data Describes the entire DB in terms of relatively simpler structures  View or External Level Highest level of abstraction which describes only a part of the DB User’s view of the DB. This level describes that part of the DB that is relevant to each user
3 Levels of Abstraction Logical or Conceptual Level Describes what data are stored in the DB & what relationships exist among those data Describes the entire DB in terms of relatively simpler structures  Implementation of these simple structures at this level may involve complex physical-level structures Users of the logical level need not be aware of this complexity DBAs, who decide what information to keep in DB, use the logical level of abstraction
Levels of Abstraction Figure taken from R2
Levels of Abstraction Many  views , single  conceptual (logical) schema   and  physical schema . Views describe how users see the data.  Conceptual schema defines logical structure Physical schema describes the files and indexes used. Schemas are defined using DDL; data is modified/queried using DML . Physical Schema Conceptual Schema View 1 View 2 View 3 Figure taken from R1
Instances & Schemas Collection of information stored in the DB at a particular moment is called an INSTANCE The overall design of the DB is called a SCHEMA A DB has many schemas Physical Conceptual/Logical Sub-schemas DB design with requirements analysis Requirements of individual users are integrated into a single community view, called “conceptual schema” Represents “entities”, their “attributes”, & their “relationships”
Instances & Schemas Is independent of the DBMS, application programs, & physical considerations Conceptual schema is translated into a schema that is compatible with the chosen DBMS Relationships between entities as reflected in the conceptual schema may not be implementable with the chosen DBMS Version of the conceptual schema that can be presented to the DBMS is called the “Logical Schema” In a RDBMS, the logical schema describes all relations stored in the DB
Instances & Schemas Users are presented with the subsets, called “subschemas”,  of the logical schema Subschemas are also in terms of the data model of the DBMS Allow data access to be customized & authorized at the level of individual users or group of users Each subschema consists of a collection of one or more “views” & relations from the logical schema Logical schema is mapped to physical storage such as disk or tape
Example: University Database Logical schema:  Students(sid: string, name: string, login: string, age: integer, gpa:real) Faculty(fid:string, fname:string, sal:real) Courses(cid: string, cname:string, credits:integer)  Enrolled(sid:string, cid:string, grade:string) Physical schema: Relations stored as unordered files.  Index on first column of Students. External Schema (View):  Course_info( cid:string,fname:string , enrollment:integer)
ANSI/SPARC 3-Tier Architecture Proposal for standard terminology & general architecture for DBSs produced in 1971 by DBTG (Data Base Task Group) appointed by Conference on DBSs & Languages (CODASYL)  DBTG recognized the need for a 2-tier architecture with system view (schema) & user view (subschema) ANSI (American National Standards Institute)-SPARC (Standards Planning & Requirements Committee) produced similar terminology & architecture in 1975(ANSI/X3/SPARC)* in 1975 ANSI-SPARC recognized the need for a 3-tier architecture *ANSI/X3/SPARC study group on DBMSs. Interim Report, FDT. ACM SIGMOD Bulletin, 7(2), 1975.
ANSI/SPARC 3-Tier Architecture Physical Schema Conceptual Schema View 1 View 2 View n External Level Conceptual/Logical Level Internal Level … Database User 1 User 2 User n Logical DI Physical DI E/C Mapping C/I Mapping
Data Independence Major objective of the 3-tier architecture is to proved data independence (DI) Upper levels are unaffected by changes at the lower level Two kinds of DI: Logical DI Physical DI
Data Independence Logical DI Immunity of the external schemas to changes in the conceptual schema Addition or removal of entities, attributes, or relationships, should be possible without having to change the external schemas or having to rewrite the application programs
Data Independence Logical DI Faculty(fid:string, fname:string, sal:real) Faculty_public(fid:string, fname: string, office:integer) Faculty_private(fid:string, sal: real) View course_info can be redefined in terms of Faculty_public & Faculty_private so that users who queries course_info gets the same answer as before
Data Independence Physical DI Immunity of the conceptual  schema to changes in the internal schema Using different file organizations or storage structures, using different storage devices, modifying indexes, or changing hashing algorithms should be possible without having to change the upper schemas Deterioration   in performance is the most common reason for internal schema changes
Data Modeling Three broad categories Object-based Use concepts such as entities, attributes, & relationships Entity-relationship Model Object-oriented Model Record-based DB consists of fixed format records of different types Each record has a fixed number of fields, each typically of fixed length Relational, Hierarchical, & Network Physical
 
 
Ad

More Related Content

What's hot (20)

Chapter 2 database architecture
Chapter 2 database architectureChapter 2 database architecture
Chapter 2 database architecture
Ura Euro
 
Database abstraction
Database abstractionDatabase abstraction
Database abstraction
RituBhargava7
 
Data abstraction in DBMS
Data abstraction in DBMSData abstraction in DBMS
Data abstraction in DBMS
Papan Sarkar
 
Data independence
Data independenceData independence
Data independence
Aashima Wadhwa
 
Ch09
Ch09Ch09
Ch09
S&P Capital IQ
 
Database fundamentals
Database fundamentalsDatabase fundamentals
Database fundamentals
LAILA ARZUMAN ARA
 
Datamodels & architecture
Datamodels & architectureDatamodels & architecture
Datamodels & architecture
Neeraj Kumar
 
Chapter02
Chapter02Chapter02
Chapter02
sasa_eldoby
 
Ch1
Ch1Ch1
Ch1
Subhankar Chowdhury
 
Dbms
DbmsDbms
Dbms
sevtap87
 
Database management system chapter1
Database management system chapter1Database management system chapter1
Database management system chapter1
Pranab Dasgupta
 
Chapter2databaseenvironment 120307033742-phpapp01
Chapter2databaseenvironment 120307033742-phpapp01Chapter2databaseenvironment 120307033742-phpapp01
Chapter2databaseenvironment 120307033742-phpapp01
Ankit Dubey
 
Architecture of-dbms-and-data-independence
Architecture of-dbms-and-data-independenceArchitecture of-dbms-and-data-independence
Architecture of-dbms-and-data-independence
Anuj Modi
 
Bab9
Bab9Bab9
Bab9
donasiilmu
 
Database Management System ppt
Database Management System pptDatabase Management System ppt
Database Management System ppt
OECLIB Odisha Electronics Control Library
 
Database Management System
Database Management SystemDatabase Management System
Database Management System
Nishant Munjal
 
Database management systems
Database management systemsDatabase management systems
Database management systems
Ravindra Singh Gohil
 
Unit 1 basic concepts of DBMS
Unit 1 basic concepts of DBMSUnit 1 basic concepts of DBMS
Unit 1 basic concepts of DBMS
Roshan Rajbhandari
 
Unit 1 DBMS
Unit 1 DBMSUnit 1 DBMS
Unit 1 DBMS
DhivyaSubramaniyam
 
Lecture 00 introduction to course
Lecture 00 introduction to courseLecture 00 introduction to course
Lecture 00 introduction to course
emailharmeet
 

Similar to Data abs ind & mod (20)

Database Management Systems.ppt
Database Management Systems.pptDatabase Management Systems.ppt
Database Management Systems.ppt
tahakhan699813
 
27 fcs157al2
27 fcs157al227 fcs157al2
27 fcs157al2
CHANDRA BHUSHAN
 
Chapter2
Chapter2Chapter2
Chapter2
Jafar Nesargi
 
Database system concepts and architecture
Database system concepts and architectureDatabase system concepts and architecture
Database system concepts and architecture
Jafar Nesargi
 
Unit 1.2.pptx
Unit 1.2.pptxUnit 1.2.pptx
Unit 1.2.pptx
ssuser0793931
 
Fundamentals of database system - Database System Concepts and Architecture
Fundamentals of database system - Database System Concepts and ArchitectureFundamentals of database system - Database System Concepts and Architecture
Fundamentals of database system - Database System Concepts and Architecture
Mustafa Kamel Mohammadi
 
DATABASE FUNCTIONS
DATABASE FUNCTIONSDATABASE FUNCTIONS
DATABASE FUNCTIONS
ghazi103
 
Dbms module i
Dbms module iDbms module i
Dbms module i
SANTOSH RATH
 
BM322_03.pptx123456786546654525165654646564
BM322_03.pptx123456786546654525165654646564BM322_03.pptx123456786546654525165654646564
BM322_03.pptx123456786546654525165654646564
DrMoizAkhtar
 
csedatabasemanagementsystemppt-170825044344.pdf
csedatabasemanagementsystemppt-170825044344.pdfcsedatabasemanagementsystemppt-170825044344.pdf
csedatabasemanagementsystemppt-170825044344.pdf
SameerKhanPathan7
 
Database-management-system-dbms-ppt.pptx
Database-management-system-dbms-ppt.pptxDatabase-management-system-dbms-ppt.pptx
Database-management-system-dbms-ppt.pptx
AnmolThakur67
 
Dbms unit i
Dbms unit iDbms unit i
Dbms unit i
Arnav Chowdhury
 
Comprehensive Guide to Effective Data Model Principles
Comprehensive Guide to Effective  Data Model PrinciplesComprehensive Guide to Effective  Data Model Principles
Comprehensive Guide to Effective Data Model Principles
EliasZerabruk
 
Database Management System Introduction
Database Management System IntroductionDatabase Management System Introduction
Database Management System Introduction
Smriti Jain
 
A N S I S P A R C Architecture
A N S I  S P A R C  ArchitectureA N S I  S P A R C  Architecture
A N S I S P A R C Architecture
Sabeeh Ahmed
 
unit 1.pptx
unit 1.pptxunit 1.pptx
unit 1.pptx
NIVETHA37590
 
Computer lecture (1) m.nasir
Computer lecture (1) m.nasirComputer lecture (1) m.nasir
Computer lecture (1) m.nasir
Muhammad Nasir
 
Unit01 dbms
Unit01 dbmsUnit01 dbms
Unit01 dbms
arnold 7490
 
data base
data basedata base
data base
Surya Swaroop
 
Database Management system, database architecture unikkkkkkkkkkkkkkk
Database Management system, database architecture unikkkkkkkkkkkkkkkDatabase Management system, database architecture unikkkkkkkkkkkkkkk
Database Management system, database architecture unikkkkkkkkkkkkkkk
sandhyakiran10
 
Database Management Systems.ppt
Database Management Systems.pptDatabase Management Systems.ppt
Database Management Systems.ppt
tahakhan699813
 
Database system concepts and architecture
Database system concepts and architectureDatabase system concepts and architecture
Database system concepts and architecture
Jafar Nesargi
 
Fundamentals of database system - Database System Concepts and Architecture
Fundamentals of database system - Database System Concepts and ArchitectureFundamentals of database system - Database System Concepts and Architecture
Fundamentals of database system - Database System Concepts and Architecture
Mustafa Kamel Mohammadi
 
DATABASE FUNCTIONS
DATABASE FUNCTIONSDATABASE FUNCTIONS
DATABASE FUNCTIONS
ghazi103
 
BM322_03.pptx123456786546654525165654646564
BM322_03.pptx123456786546654525165654646564BM322_03.pptx123456786546654525165654646564
BM322_03.pptx123456786546654525165654646564
DrMoizAkhtar
 
csedatabasemanagementsystemppt-170825044344.pdf
csedatabasemanagementsystemppt-170825044344.pdfcsedatabasemanagementsystemppt-170825044344.pdf
csedatabasemanagementsystemppt-170825044344.pdf
SameerKhanPathan7
 
Database-management-system-dbms-ppt.pptx
Database-management-system-dbms-ppt.pptxDatabase-management-system-dbms-ppt.pptx
Database-management-system-dbms-ppt.pptx
AnmolThakur67
 
Comprehensive Guide to Effective Data Model Principles
Comprehensive Guide to Effective  Data Model PrinciplesComprehensive Guide to Effective  Data Model Principles
Comprehensive Guide to Effective Data Model Principles
EliasZerabruk
 
Database Management System Introduction
Database Management System IntroductionDatabase Management System Introduction
Database Management System Introduction
Smriti Jain
 
A N S I S P A R C Architecture
A N S I  S P A R C  ArchitectureA N S I  S P A R C  Architecture
A N S I S P A R C Architecture
Sabeeh Ahmed
 
Computer lecture (1) m.nasir
Computer lecture (1) m.nasirComputer lecture (1) m.nasir
Computer lecture (1) m.nasir
Muhammad Nasir
 
Database Management system, database architecture unikkkkkkkkkkkkkkk
Database Management system, database architecture unikkkkkkkkkkkkkkkDatabase Management system, database architecture unikkkkkkkkkkkkkkk
Database Management system, database architecture unikkkkkkkkkkkkkkk
sandhyakiran10
 
Ad

Recently uploaded (20)

TNR Gold Investor Summary - Building The Green Energy Metals Royalty and Gold...
TNR Gold Investor Summary - Building The Green Energy Metals Royalty and Gold...TNR Gold Investor Summary - Building The Green Energy Metals Royalty and Gold...
TNR Gold Investor Summary - Building The Green Energy Metals Royalty and Gold...
Kirill Klip
 
Top 5 Mistakes to Avoid When Writing a Job Application
Top 5 Mistakes to Avoid When Writing a Job ApplicationTop 5 Mistakes to Avoid When Writing a Job Application
Top 5 Mistakes to Avoid When Writing a Job Application
Red Tape Busters
 
Alan Stalcup - The Enterprising CEO
Alan  Stalcup  -  The  Enterprising  CEOAlan  Stalcup  -  The  Enterprising  CEO
Alan Stalcup - The Enterprising CEO
Alan Stalcup
 
Kiran Flemish - A Dynamic Musician
Kiran  Flemish  -  A   Dynamic  MusicianKiran  Flemish  -  A   Dynamic  Musician
Kiran Flemish - A Dynamic Musician
Kiran Flemish
 
Alec Lawler - A Passion For Building Brand Awareness
Alec Lawler - A Passion For Building Brand AwarenessAlec Lawler - A Passion For Building Brand Awareness
Alec Lawler - A Passion For Building Brand Awareness
Alec Lawler
 
TMG - Q3 2025 Earnings Call Slides - v4.pptx
TMG - Q3 2025 Earnings Call Slides - v4.pptxTMG - Q3 2025 Earnings Call Slides - v4.pptx
TMG - Q3 2025 Earnings Call Slides - v4.pptx
Marketing847413
 
Petslify Turns Pet Photos into Hug-Worthy Memories
Petslify Turns Pet Photos into Hug-Worthy MemoriesPetslify Turns Pet Photos into Hug-Worthy Memories
Petslify Turns Pet Photos into Hug-Worthy Memories
Petslify
 
BeMetals_Presentation_May_2025 .pdf
BeMetals_Presentation_May_2025      .pdfBeMetals_Presentation_May_2025      .pdf
BeMetals_Presentation_May_2025 .pdf
DerekIwanaka2
 
From Sunlight to Savings The Rise of Homegrown Solar Power.pdf
From Sunlight to Savings The Rise of Homegrown Solar Power.pdfFrom Sunlight to Savings The Rise of Homegrown Solar Power.pdf
From Sunlight to Savings The Rise of Homegrown Solar Power.pdf
Insolation Energy
 
Harnessing Hyper-Localisation: A New Era in Retail Strategy
Harnessing Hyper-Localisation: A New Era in Retail StrategyHarnessing Hyper-Localisation: A New Era in Retail Strategy
Harnessing Hyper-Localisation: A New Era in Retail Strategy
RUPAL AGARWAL
 
Solaris Resources Presentation - Corporate April 2025.pdf
Solaris Resources Presentation - Corporate April 2025.pdfSolaris Resources Presentation - Corporate April 2025.pdf
Solaris Resources Presentation - Corporate April 2025.pdf
pchambers2
 
20250428 CDB Investor Deck_Apr25_vFF.pdf
20250428 CDB Investor Deck_Apr25_vFF.pdf20250428 CDB Investor Deck_Apr25_vFF.pdf
20250428 CDB Investor Deck_Apr25_vFF.pdf
yihong30
 
LDMMIA Bday celebration 2025 Gifts information
LDMMIA Bday celebration 2025 Gifts informationLDMMIA Bday celebration 2025 Gifts information
LDMMIA Bday celebration 2025 Gifts information
LDM Mia eStudios
 
Comments on Cloud Stream Part II Mobile Hub V1 Hub Agency.pdf
Comments on Cloud Stream Part II Mobile Hub V1 Hub Agency.pdfComments on Cloud Stream Part II Mobile Hub V1 Hub Agency.pdf
Comments on Cloud Stream Part II Mobile Hub V1 Hub Agency.pdf
Brij Consulting, LLC
 
CGG Deck English - Apr 2025-edit (1).pptx
CGG Deck English - Apr 2025-edit (1).pptxCGG Deck English - Apr 2025-edit (1).pptx
CGG Deck English - Apr 2025-edit (1).pptx
China_Gold_International_Resources
 
INTRODUCTION OF MANAGEMENT.pdf CA SUVIDHA CHAPLOT
INTRODUCTION OF MANAGEMENT.pdf CA SUVIDHA CHAPLOTINTRODUCTION OF MANAGEMENT.pdf CA SUVIDHA CHAPLOT
INTRODUCTION OF MANAGEMENT.pdf CA SUVIDHA CHAPLOT
CA Suvidha Chaplot
 
Accounting_Basics_Complete_Guide_By_CA_Suvidha_Chaplot (1).pdf
Accounting_Basics_Complete_Guide_By_CA_Suvidha_Chaplot (1).pdfAccounting_Basics_Complete_Guide_By_CA_Suvidha_Chaplot (1).pdf
Accounting_Basics_Complete_Guide_By_CA_Suvidha_Chaplot (1).pdf
CA Suvidha Chaplot
 
EquariusAI analytics for business water risk
EquariusAI analytics for business water riskEquariusAI analytics for business water risk
EquariusAI analytics for business water risk
Peter Adriaens
 
Treis & Friends One sheet - Portfolio IV
Treis & Friends One sheet - Portfolio IVTreis & Friends One sheet - Portfolio IV
Treis & Friends One sheet - Portfolio IV
aparicioregina7
 
waterBeta white paper - 250202- two-column.docx
waterBeta white paper - 250202- two-column.docxwaterBeta white paper - 250202- two-column.docx
waterBeta white paper - 250202- two-column.docx
Peter Adriaens
 
TNR Gold Investor Summary - Building The Green Energy Metals Royalty and Gold...
TNR Gold Investor Summary - Building The Green Energy Metals Royalty and Gold...TNR Gold Investor Summary - Building The Green Energy Metals Royalty and Gold...
TNR Gold Investor Summary - Building The Green Energy Metals Royalty and Gold...
Kirill Klip
 
Top 5 Mistakes to Avoid When Writing a Job Application
Top 5 Mistakes to Avoid When Writing a Job ApplicationTop 5 Mistakes to Avoid When Writing a Job Application
Top 5 Mistakes to Avoid When Writing a Job Application
Red Tape Busters
 
Alan Stalcup - The Enterprising CEO
Alan  Stalcup  -  The  Enterprising  CEOAlan  Stalcup  -  The  Enterprising  CEO
Alan Stalcup - The Enterprising CEO
Alan Stalcup
 
Kiran Flemish - A Dynamic Musician
Kiran  Flemish  -  A   Dynamic  MusicianKiran  Flemish  -  A   Dynamic  Musician
Kiran Flemish - A Dynamic Musician
Kiran Flemish
 
Alec Lawler - A Passion For Building Brand Awareness
Alec Lawler - A Passion For Building Brand AwarenessAlec Lawler - A Passion For Building Brand Awareness
Alec Lawler - A Passion For Building Brand Awareness
Alec Lawler
 
TMG - Q3 2025 Earnings Call Slides - v4.pptx
TMG - Q3 2025 Earnings Call Slides - v4.pptxTMG - Q3 2025 Earnings Call Slides - v4.pptx
TMG - Q3 2025 Earnings Call Slides - v4.pptx
Marketing847413
 
Petslify Turns Pet Photos into Hug-Worthy Memories
Petslify Turns Pet Photos into Hug-Worthy MemoriesPetslify Turns Pet Photos into Hug-Worthy Memories
Petslify Turns Pet Photos into Hug-Worthy Memories
Petslify
 
BeMetals_Presentation_May_2025 .pdf
BeMetals_Presentation_May_2025      .pdfBeMetals_Presentation_May_2025      .pdf
BeMetals_Presentation_May_2025 .pdf
DerekIwanaka2
 
From Sunlight to Savings The Rise of Homegrown Solar Power.pdf
From Sunlight to Savings The Rise of Homegrown Solar Power.pdfFrom Sunlight to Savings The Rise of Homegrown Solar Power.pdf
From Sunlight to Savings The Rise of Homegrown Solar Power.pdf
Insolation Energy
 
Harnessing Hyper-Localisation: A New Era in Retail Strategy
Harnessing Hyper-Localisation: A New Era in Retail StrategyHarnessing Hyper-Localisation: A New Era in Retail Strategy
Harnessing Hyper-Localisation: A New Era in Retail Strategy
RUPAL AGARWAL
 
Solaris Resources Presentation - Corporate April 2025.pdf
Solaris Resources Presentation - Corporate April 2025.pdfSolaris Resources Presentation - Corporate April 2025.pdf
Solaris Resources Presentation - Corporate April 2025.pdf
pchambers2
 
20250428 CDB Investor Deck_Apr25_vFF.pdf
20250428 CDB Investor Deck_Apr25_vFF.pdf20250428 CDB Investor Deck_Apr25_vFF.pdf
20250428 CDB Investor Deck_Apr25_vFF.pdf
yihong30
 
LDMMIA Bday celebration 2025 Gifts information
LDMMIA Bday celebration 2025 Gifts informationLDMMIA Bday celebration 2025 Gifts information
LDMMIA Bday celebration 2025 Gifts information
LDM Mia eStudios
 
Comments on Cloud Stream Part II Mobile Hub V1 Hub Agency.pdf
Comments on Cloud Stream Part II Mobile Hub V1 Hub Agency.pdfComments on Cloud Stream Part II Mobile Hub V1 Hub Agency.pdf
Comments on Cloud Stream Part II Mobile Hub V1 Hub Agency.pdf
Brij Consulting, LLC
 
INTRODUCTION OF MANAGEMENT.pdf CA SUVIDHA CHAPLOT
INTRODUCTION OF MANAGEMENT.pdf CA SUVIDHA CHAPLOTINTRODUCTION OF MANAGEMENT.pdf CA SUVIDHA CHAPLOT
INTRODUCTION OF MANAGEMENT.pdf CA SUVIDHA CHAPLOT
CA Suvidha Chaplot
 
Accounting_Basics_Complete_Guide_By_CA_Suvidha_Chaplot (1).pdf
Accounting_Basics_Complete_Guide_By_CA_Suvidha_Chaplot (1).pdfAccounting_Basics_Complete_Guide_By_CA_Suvidha_Chaplot (1).pdf
Accounting_Basics_Complete_Guide_By_CA_Suvidha_Chaplot (1).pdf
CA Suvidha Chaplot
 
EquariusAI analytics for business water risk
EquariusAI analytics for business water riskEquariusAI analytics for business water risk
EquariusAI analytics for business water risk
Peter Adriaens
 
Treis & Friends One sheet - Portfolio IV
Treis & Friends One sheet - Portfolio IVTreis & Friends One sheet - Portfolio IV
Treis & Friends One sheet - Portfolio IV
aparicioregina7
 
waterBeta white paper - 250202- two-column.docx
waterBeta white paper - 250202- two-column.docxwaterBeta white paper - 250202- two-column.docx
waterBeta white paper - 250202- two-column.docx
Peter Adriaens
 
Ad

Data abs ind & mod

  • 1.  
  • 2. Topics for Today Data Abstraction Data Independence Data Modeling
  • 3. Data Abstraction Why it is Important? How it is provided by a DBMS? 3 levels of abstraction Physical or Internal Level Logical Level View or External Level
  • 4. Data Independence What is Data Independence? Why it is Important? How it is provided by a DBMS? Types of Independence Physical Data Independence Logical Data Independence
  • 5. Data Modeling What is Data Modeling? An integrated collection of concepts for describing & manipulating data, relationships between data, & constraints on the data in an organization Used for defining Database Schemas Databases have several schemas, partitioned according to levels of abstraction Schema Levels Physical Schema Conceptual/Logical Schema Sub-schemas or external schemas
  • 6. Popular Data Models Entity-Relationship Model Relational Model Hierarchical Model Network Model Inverted File Model Object-Oriented Model Object-Relational Model
  • 7. Data Abstraction Major aim of a DBMS is to provide users with an abstract view of data Hides certain details of how the data are stored & maintained DBMS must retrieve data efficiently Need for efficiency has led designers to use complex data structures to represent the data in the database Most DB users are not computer trained, developers hide complexity through several levels of abstraction to simplify user’s interaction with the systems
  • 8. 3 Levels of Abstraction Physical or Internal Level Lowest level of abstraction describes how data are actually stored Describes complex low-level data structures in detail Logical or Conceptual Level Describes what data are stored in the DB & what relationships exist among those data Describes the entire DB in terms of relatively simpler structures View or External Level Highest level of abstraction which describes only a part of the DB User’s view of the DB. This level describes that part of the DB that is relevant to each user
  • 9. 3 Levels of Abstraction Logical or Conceptual Level Describes what data are stored in the DB & what relationships exist among those data Describes the entire DB in terms of relatively simpler structures Implementation of these simple structures at this level may involve complex physical-level structures Users of the logical level need not be aware of this complexity DBAs, who decide what information to keep in DB, use the logical level of abstraction
  • 10. Levels of Abstraction Figure taken from R2
  • 11. Levels of Abstraction Many views , single conceptual (logical) schema and physical schema . Views describe how users see the data. Conceptual schema defines logical structure Physical schema describes the files and indexes used. Schemas are defined using DDL; data is modified/queried using DML . Physical Schema Conceptual Schema View 1 View 2 View 3 Figure taken from R1
  • 12. Instances & Schemas Collection of information stored in the DB at a particular moment is called an INSTANCE The overall design of the DB is called a SCHEMA A DB has many schemas Physical Conceptual/Logical Sub-schemas DB design with requirements analysis Requirements of individual users are integrated into a single community view, called “conceptual schema” Represents “entities”, their “attributes”, & their “relationships”
  • 13. Instances & Schemas Is independent of the DBMS, application programs, & physical considerations Conceptual schema is translated into a schema that is compatible with the chosen DBMS Relationships between entities as reflected in the conceptual schema may not be implementable with the chosen DBMS Version of the conceptual schema that can be presented to the DBMS is called the “Logical Schema” In a RDBMS, the logical schema describes all relations stored in the DB
  • 14. Instances & Schemas Users are presented with the subsets, called “subschemas”, of the logical schema Subschemas are also in terms of the data model of the DBMS Allow data access to be customized & authorized at the level of individual users or group of users Each subschema consists of a collection of one or more “views” & relations from the logical schema Logical schema is mapped to physical storage such as disk or tape
  • 15. Example: University Database Logical schema: Students(sid: string, name: string, login: string, age: integer, gpa:real) Faculty(fid:string, fname:string, sal:real) Courses(cid: string, cname:string, credits:integer) Enrolled(sid:string, cid:string, grade:string) Physical schema: Relations stored as unordered files. Index on first column of Students. External Schema (View): Course_info( cid:string,fname:string , enrollment:integer)
  • 16. ANSI/SPARC 3-Tier Architecture Proposal for standard terminology & general architecture for DBSs produced in 1971 by DBTG (Data Base Task Group) appointed by Conference on DBSs & Languages (CODASYL) DBTG recognized the need for a 2-tier architecture with system view (schema) & user view (subschema) ANSI (American National Standards Institute)-SPARC (Standards Planning & Requirements Committee) produced similar terminology & architecture in 1975(ANSI/X3/SPARC)* in 1975 ANSI-SPARC recognized the need for a 3-tier architecture *ANSI/X3/SPARC study group on DBMSs. Interim Report, FDT. ACM SIGMOD Bulletin, 7(2), 1975.
  • 17. ANSI/SPARC 3-Tier Architecture Physical Schema Conceptual Schema View 1 View 2 View n External Level Conceptual/Logical Level Internal Level … Database User 1 User 2 User n Logical DI Physical DI E/C Mapping C/I Mapping
  • 18. Data Independence Major objective of the 3-tier architecture is to proved data independence (DI) Upper levels are unaffected by changes at the lower level Two kinds of DI: Logical DI Physical DI
  • 19. Data Independence Logical DI Immunity of the external schemas to changes in the conceptual schema Addition or removal of entities, attributes, or relationships, should be possible without having to change the external schemas or having to rewrite the application programs
  • 20. Data Independence Logical DI Faculty(fid:string, fname:string, sal:real) Faculty_public(fid:string, fname: string, office:integer) Faculty_private(fid:string, sal: real) View course_info can be redefined in terms of Faculty_public & Faculty_private so that users who queries course_info gets the same answer as before
  • 21. Data Independence Physical DI Immunity of the conceptual schema to changes in the internal schema Using different file organizations or storage structures, using different storage devices, modifying indexes, or changing hashing algorithms should be possible without having to change the upper schemas Deterioration in performance is the most common reason for internal schema changes
  • 22. Data Modeling Three broad categories Object-based Use concepts such as entities, attributes, & relationships Entity-relationship Model Object-oriented Model Record-based DB consists of fixed format records of different types Each record has a fixed number of fields, each typically of fixed length Relational, Hierarchical, & Network Physical
  • 23.  
  • 24.  

Editor's Notes