SlideShare uma empresa Scribd logo
1 de 12
Subject Name Code Credit Hours
Database System COMP 219 3
Chapter VII
Subject Name Code Credit Hours
Database System COMP 219 3
Relational Model:
• It uses a collection of tables to represent
both data and relationships among those
data.
Basic Structure
 In this model each table is called as
relation. Each relation has a no. of
row is called tuples and columns
called as fields or attributes.
Subject Name Code Credit Hours
Database System COMP 219 3
Relational Model:
• For an attribute, a range of permitted values
can be specified. That range is called as
Domain of that attribute.
• E.g.. Age – attribute
• Domain (Age) = {1,2…100}
Subject Name Code Credit Hours
Database System COMP 219 3
Relational Model:
• A table of n attributes must be a subset of
D1*D2*…….Dn
• E.g..
Eid Ename Eaddr
1
2
3
Aaa
Bbb
ccc
South street
West street
New
Employee Relation
Subject Name Code Credit Hours
Database System COMP 219 3
Relational Model:
• To denote the value of attribute ‘a’ on second
tuple, then it can be denoted as t2[a]=value.
• E.g..
• t2[ename]=“bbb”.
Subject Name Code Credit Hours
Database System COMP 219 3
Relation schema
• It is the description about the structure of the
relation and the relation instance is the
snapshot of data in the relation at a given
instant in time.
• E.g.. Employee_schema=(eid,ename,eaddr)
Name of the schema
Subject Name Code Credit Hours
Database System COMP 219 3
Relation schema
• Empoyee(Employee_schema) denote that
• Employee is a relation on Employee_schema
Subject Name Code Credit Hours
Database System COMP 219 3
Keys
• Strong Entity set:
• The Primary key of the entity set becomes the primary
key of the relation.
• Weak Entity Set:
• The table corresponding a weak entity set includes
• the attributes of the weak entity set &
• primary key of the strong entity set on which the weak
entity set depends.
Subject Name Code Credit Hours
Database System COMP 219 3
Keys
Relationship Set:
The union of the primary key of the related entity sets
becomes a super key of the relation.
Combined Tables:
If there exists many to one relationship set from A to B,
then the prim.key of A becomes the prim.key of the
relation & the relation consists of the attribues of A and
attributes of the relationship set.
Subject Name Code Credit Hours
Database System COMP 219 3
Keys
Foreign Key:
An attribute of a relation r1 that references
relation r2 is called as foreign key attribute.
Schema Diagram:
A relation schema can be depicted pictorially
by schema diagram,
Subject Name Code Credit Hours
Database System COMP 219 3
Keys
• E.g..
eid Ename eaddr dno
dnamedno dloc
Employee
pnamepno eid
Dept
Project
Subject Name Code Credit Hours
Database System COMP 219 3
Query Languages:
• It is a lang in which a user requests
information from db.
Query Languages
Procedural Language Non Procedural Language
Specifies what data are required &
specify how to get those data e.g
Relational Algebra
Specifies what data are required without
specify how to get those data e.g.
Relational calculus

Mais conteúdo relacionado

Semelhante a Dbms chapter vii

4_RelationalDataModelAndRelationalMapping.pdf
4_RelationalDataModelAndRelationalMapping.pdf4_RelationalDataModelAndRelationalMapping.pdf
4_RelationalDataModelAndRelationalMapping.pdf
LPhct2
 

Semelhante a Dbms chapter vii (20)

Relational model
Relational modelRelational model
Relational model
 
Relational model
Relational modelRelational model
Relational model
 
Dmbs chapter vi
Dmbs chapter viDmbs chapter vi
Dmbs chapter vi
 
Dbms relational data model and sql queries
Dbms relational data model and sql queries Dbms relational data model and sql queries
Dbms relational data model and sql queries
 
Relational model and its utility%28 rajkumar%29.pptx
Relational model and its       utility%28 rajkumar%29.pptxRelational model and its       utility%28 rajkumar%29.pptx
Relational model and its utility%28 rajkumar%29.pptx
 
Unit 04 dbms
Unit 04 dbmsUnit 04 dbms
Unit 04 dbms
 
7.relational model
7.relational model7.relational model
7.relational model
 
Relational model
Relational modelRelational model
Relational model
 
Unit04 dbms
Unit04 dbmsUnit04 dbms
Unit04 dbms
 
Relational model
Relational modelRelational model
Relational model
 
Relational Database and Relational Algebra
Relational Database and Relational AlgebraRelational Database and Relational Algebra
Relational Database and Relational Algebra
 
DATABASE DESIGN.pptx
DATABASE DESIGN.pptxDATABASE DESIGN.pptx
DATABASE DESIGN.pptx
 
Relational Model on Database management PPT
Relational Model on Database management PPTRelational Model on Database management PPT
Relational Model on Database management PPT
 
DBMS Unit-2.pdf
DBMS Unit-2.pdfDBMS Unit-2.pdf
DBMS Unit-2.pdf
 
DBMS Class 3
DBMS Class 3DBMS Class 3
DBMS Class 3
 
ER Digramms by Harshal wagh
ER Digramms by Harshal waghER Digramms by Harshal wagh
ER Digramms by Harshal wagh
 
Relational Algebra
Relational AlgebraRelational Algebra
Relational Algebra
 
basic structure of SQL FINAL.pptx
basic structure of SQL FINAL.pptxbasic structure of SQL FINAL.pptx
basic structure of SQL FINAL.pptx
 
4_RelationalDataModelAndRelationalMapping.pdf
4_RelationalDataModelAndRelationalMapping.pdf4_RelationalDataModelAndRelationalMapping.pdf
4_RelationalDataModelAndRelationalMapping.pdf
 
RDBMS
RDBMSRDBMS
RDBMS
 

Mais de Bala Ganesh

Dbms chapter iii
Dbms chapter iiiDbms chapter iii
Dbms chapter iii
Bala Ganesh
 
Flip flop& RAM ROM
Flip flop& RAM ROMFlip flop& RAM ROM
Flip flop& RAM ROM
Bala Ganesh
 
Chap iii-Logic Gates
Chap iii-Logic GatesChap iii-Logic Gates
Chap iii-Logic Gates
Bala Ganesh
 
Chap ii.BCD code,Gray code
Chap ii.BCD code,Gray codeChap ii.BCD code,Gray code
Chap ii.BCD code,Gray code
Bala Ganesh
 
Software engineering Questions and Answers
Software engineering Questions and AnswersSoftware engineering Questions and Answers
Software engineering Questions and Answers
Bala Ganesh
 
Software testing
Software testingSoftware testing
Software testing
Bala Ganesh
 
Software Requirements
Software RequirementsSoftware Requirements
Software Requirements
Bala Ganesh
 
Comp 111chp iv vi
Comp 111chp iv viComp 111chp iv vi
Comp 111chp iv vi
Bala Ganesh
 
Comp 107cep iii,iv,v
Comp 107cep iii,iv,vComp 107cep iii,iv,v
Comp 107cep iii,iv,v
Bala Ganesh
 
Wdf 222chp iii vi
Wdf 222chp iii viWdf 222chp iii vi
Wdf 222chp iii vi
Bala Ganesh
 

Mais de Bala Ganesh (20)

Dbms chapter iii
Dbms chapter iiiDbms chapter iii
Dbms chapter iii
 
Dbms chapter ii
Dbms chapter iiDbms chapter ii
Dbms chapter ii
 
Flip flop& RAM ROM
Flip flop& RAM ROMFlip flop& RAM ROM
Flip flop& RAM ROM
 
karnaugh maps
karnaugh mapskarnaugh maps
karnaugh maps
 
Chap iii-Logic Gates
Chap iii-Logic GatesChap iii-Logic Gates
Chap iii-Logic Gates
 
Chap ii.BCD code,Gray code
Chap ii.BCD code,Gray codeChap ii.BCD code,Gray code
Chap ii.BCD code,Gray code
 
DEL-244Chep i
DEL-244Chep iDEL-244Chep i
DEL-244Chep i
 
Software engineering Questions and Answers
Software engineering Questions and AnswersSoftware engineering Questions and Answers
Software engineering Questions and Answers
 
Software testing
Software testingSoftware testing
Software testing
 
Design
DesignDesign
Design
 
Comp 107 cep 8
Comp 107 cep 8Comp 107 cep 8
Comp 107 cep 8
 
Comp 107 cep 7
Comp 107 cep 7Comp 107 cep 7
Comp 107 cep 7
 
Cocomo model
Cocomo modelCocomo model
Cocomo model
 
Software Requirements
Software RequirementsSoftware Requirements
Software Requirements
 
Comp107 chep6
Comp107 chep6Comp107 chep6
Comp107 chep6
 
Comp 111chp iv vi
Comp 111chp iv viComp 111chp iv vi
Comp 111chp iv vi
 
Comp 111 cep ii
Comp 111 cep iiComp 111 cep ii
Comp 111 cep ii
 
Comp 107cep iii,iv,v
Comp 107cep iii,iv,vComp 107cep iii,iv,v
Comp 107cep iii,iv,v
 
Wdf 222chp iii vi
Wdf 222chp iii viWdf 222chp iii vi
Wdf 222chp iii vi
 
Wdf222 cep ii
Wdf222 cep iiWdf222 cep ii
Wdf222 cep ii
 

Último

1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
QucHHunhnh
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
ciinovamais
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
QucHHunhnh
 
Gardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch LetterGardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch Letter
MateoGardella
 
An Overview of Mutual Funds Bcom Project.pdf
An Overview of Mutual Funds Bcom Project.pdfAn Overview of Mutual Funds Bcom Project.pdf
An Overview of Mutual Funds Bcom Project.pdf
SanaAli374401
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
heathfieldcps1
 

Último (20)

Unit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptxUnit-IV; Professional Sales Representative (PSR).pptx
Unit-IV; Professional Sales Representative (PSR).pptx
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Gardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch LetterGardella_PRCampaignConclusion Pitch Letter
Gardella_PRCampaignConclusion Pitch Letter
 
PROCESS RECORDING FORMAT.docx
PROCESS      RECORDING        FORMAT.docxPROCESS      RECORDING        FORMAT.docx
PROCESS RECORDING FORMAT.docx
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.
 
Application orientated numerical on hev.ppt
Application orientated numerical on hev.pptApplication orientated numerical on hev.ppt
Application orientated numerical on hev.ppt
 
An Overview of Mutual Funds Bcom Project.pdf
An Overview of Mutual Funds Bcom Project.pdfAn Overview of Mutual Funds Bcom Project.pdf
An Overview of Mutual Funds Bcom Project.pdf
 
psychiatric nursing HISTORY COLLECTION .docx
psychiatric  nursing HISTORY  COLLECTION  .docxpsychiatric  nursing HISTORY  COLLECTION  .docx
psychiatric nursing HISTORY COLLECTION .docx
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
 
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptxINDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..Sports & Fitness Value Added Course FY..
Sports & Fitness Value Added Course FY..
 
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
Ecological Succession. ( ECOSYSTEM, B. Pharmacy, 1st Year, Sem-II, Environmen...
 
Unit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptxUnit-IV- Pharma. Marketing Channels.pptx
Unit-IV- Pharma. Marketing Channels.pptx
 

Dbms chapter vii

  • 1. Subject Name Code Credit Hours Database System COMP 219 3 Chapter VII
  • 2. Subject Name Code Credit Hours Database System COMP 219 3 Relational Model: • It uses a collection of tables to represent both data and relationships among those data. Basic Structure  In this model each table is called as relation. Each relation has a no. of row is called tuples and columns called as fields or attributes.
  • 3. Subject Name Code Credit Hours Database System COMP 219 3 Relational Model: • For an attribute, a range of permitted values can be specified. That range is called as Domain of that attribute. • E.g.. Age – attribute • Domain (Age) = {1,2…100}
  • 4. Subject Name Code Credit Hours Database System COMP 219 3 Relational Model: • A table of n attributes must be a subset of D1*D2*…….Dn • E.g.. Eid Ename Eaddr 1 2 3 Aaa Bbb ccc South street West street New Employee Relation
  • 5. Subject Name Code Credit Hours Database System COMP 219 3 Relational Model: • To denote the value of attribute ‘a’ on second tuple, then it can be denoted as t2[a]=value. • E.g.. • t2[ename]=“bbb”.
  • 6. Subject Name Code Credit Hours Database System COMP 219 3 Relation schema • It is the description about the structure of the relation and the relation instance is the snapshot of data in the relation at a given instant in time. • E.g.. Employee_schema=(eid,ename,eaddr) Name of the schema
  • 7. Subject Name Code Credit Hours Database System COMP 219 3 Relation schema • Empoyee(Employee_schema) denote that • Employee is a relation on Employee_schema
  • 8. Subject Name Code Credit Hours Database System COMP 219 3 Keys • Strong Entity set: • The Primary key of the entity set becomes the primary key of the relation. • Weak Entity Set: • The table corresponding a weak entity set includes • the attributes of the weak entity set & • primary key of the strong entity set on which the weak entity set depends.
  • 9. Subject Name Code Credit Hours Database System COMP 219 3 Keys Relationship Set: The union of the primary key of the related entity sets becomes a super key of the relation. Combined Tables: If there exists many to one relationship set from A to B, then the prim.key of A becomes the prim.key of the relation & the relation consists of the attribues of A and attributes of the relationship set.
  • 10. Subject Name Code Credit Hours Database System COMP 219 3 Keys Foreign Key: An attribute of a relation r1 that references relation r2 is called as foreign key attribute. Schema Diagram: A relation schema can be depicted pictorially by schema diagram,
  • 11. Subject Name Code Credit Hours Database System COMP 219 3 Keys • E.g.. eid Ename eaddr dno dnamedno dloc Employee pnamepno eid Dept Project
  • 12. Subject Name Code Credit Hours Database System COMP 219 3 Query Languages: • It is a lang in which a user requests information from db. Query Languages Procedural Language Non Procedural Language Specifies what data are required & specify how to get those data e.g Relational Algebra Specifies what data are required without specify how to get those data e.g. Relational calculus