SlideShare una empresa de Scribd logo
1 de 9
Subject Name Code Credit Hours
Database System COMP 219 3
Chapter V
Subject Name Code Credit Hours
Database System COMP 219 3
Keys
• It is used to uniquely identify entities within a
given entityset or a relationship set.
• Keys in Entity set:
• (i) Primary Key:
– It is a key used to uniquely identify an entity in the
entity set.
– E,g, eno,rno,dno etc…
Subject Name Code Credit Hours
Database System COMP 219 3
Keys
• Super Key:
• It is a set of one or more attributes that
allow us to uniquely identify an entity in the
entity set. Among them one must be a
primary key attribute.
• E.G.. Eid (primary key) and ename together
can be identify an entity in entity set.
Subject Name Code Credit Hours
Database System COMP 219 3
Keys
• Candidate key:
• They are minimal super keys for which no proper
subset is a superkey.
• E.g.. Ename and eaddr can be sufficient to identify an
employee in employee set.
• {eid} and {ename,eaddr} – Candidate keys
Subject Name Code Credit Hours
Database System COMP 219 3
FOREIGN -----------------------Keys
• An attribute which makes a reference to an
attribute of another entity type is called
foreign key
Subject Name Code Credit Hours
Database System COMP 219 3
Key
 E.g…
eid Ename eaddr dno
dnamedno dloc
Employee – E1
Dept – E2
Foreign Ke
Subject Name Code Credit Hours
Database System COMP 219 3
Domain
• A range of values can be defined for an
attribute and is called as Domain of that attribute.
• E.g.. Age – attribute A
• Domain (A)= {1,2,….100}
Subject Name Code Credit Hours
Database System COMP 219 3
Keys in Relationship set:
• Case 1: If the relationship set R has no
attributes, then the set of attributes
Primarykey(E1) U Primarykey(E2) U
Primarykey (n)
Case2: If the relationship set R has attributes,
then the set of attributes,
Subject Name Code Credit Hours
Database System COMP 219 3
Keys in Relationship set
Primarykey(E1) U Primarykey(E2) U Primarykey
(n)U{a1,a2,…an}
describes an individual relationship in set R.
In both cases,
Primarykey(E1) U Primarykey(E2) U Primarykey (n)
forms a superkey for a relationship set.

Más contenido relacionado

Destacado

Consumer Awareness
Consumer AwarenessConsumer Awareness
Consumer AwarenessKQED
 
Software engineering Questions and Answers
Software engineering Questions and AnswersSoftware engineering Questions and Answers
Software engineering Questions and AnswersBala Ganesh
 
Money Market Ppt
Money Market PptMoney Market Ppt
Money Market Pptshael_kumar
 
Money market & Capital market
Money market & Capital marketMoney market & Capital market
Money market & Capital marketNowshed Hossain
 
Money market & its instruments
Money market & its instrumentsMoney market & its instruments
Money market & its instrumentsabhishek rane
 
instruments of Money market and capital market
instruments of Money market and capital marketinstruments of Money market and capital market
instruments of Money market and capital marketVikash Gupta
 
money market and capital market
money market and capital marketmoney market and capital market
money market and capital marketPrateek Nepal
 

Destacado (15)

Consumer Awareness
Consumer AwarenessConsumer Awareness
Consumer Awareness
 
Software engineering Questions and Answers
Software engineering Questions and AnswersSoftware engineering Questions and Answers
Software engineering Questions and Answers
 
Final project on Capital Market
Final project on Capital MarketFinal project on Capital Market
Final project on Capital Market
 
CONSUMER AWARENES PPT
CONSUMER AWARENES PPTCONSUMER AWARENES PPT
CONSUMER AWARENES PPT
 
Cocomo model
Cocomo modelCocomo model
Cocomo model
 
Money Market Ppt
Money Market PptMoney Market Ppt
Money Market Ppt
 
Money market & Capital market
Money market & Capital marketMoney market & Capital market
Money market & Capital market
 
Capital Market
Capital MarketCapital Market
Capital Market
 
Capital market ppt
Capital market pptCapital market ppt
Capital market ppt
 
Capital market ppt
Capital market pptCapital market ppt
Capital market ppt
 
Money market & its instruments
Money market & its instrumentsMoney market & its instruments
Money market & its instruments
 
Cocomo model
Cocomo modelCocomo model
Cocomo model
 
instruments of Money market and capital market
instruments of Money market and capital marketinstruments of Money market and capital market
instruments of Money market and capital market
 
money market and capital market
money market and capital marketmoney market and capital market
money market and capital market
 
Consumer awareness
Consumer awarenessConsumer awareness
Consumer awareness
 

Similar a Dbms chapter v

2. Relational_Data_Model_Keys_10b.pptx
2. Relational_Data_Model_Keys_10b.pptx2. Relational_Data_Model_Keys_10b.pptx
2. Relational_Data_Model_Keys_10b.pptxvidyahulkman
 
"Python Dictionary: The Key to Efficient Data Storage, Manipulation, and Vers...
"Python Dictionary: The Key to Efficient Data Storage, Manipulation, and Vers..."Python Dictionary: The Key to Efficient Data Storage, Manipulation, and Vers...
"Python Dictionary: The Key to Efficient Data Storage, Manipulation, and Vers...ZainabHaneen
 
Free video lectures for mca
Free video lectures for mcaFree video lectures for mca
Free video lectures for mcaEdhole.com
 
ER diagram slides for datanase stujdy-1.pdf
ER diagram slides for datanase stujdy-1.pdfER diagram slides for datanase stujdy-1.pdf
ER diagram slides for datanase stujdy-1.pdfSadiaSharmin40
 
ER Digramms by Harshal wagh
ER Digramms by Harshal waghER Digramms by Harshal wagh
ER Digramms by Harshal waghharshalkwagh999
 
Summary data modelling
Summary data modellingSummary data modelling
Summary data modellingNovita Sari
 
Exploiting web search engines to search structured
Exploiting web search engines to search structuredExploiting web search engines to search structured
Exploiting web search engines to search structuredNita Pawar
 
Relational Model on Database management PPT
Relational Model on Database management PPTRelational Model on Database management PPT
Relational Model on Database management PPTssuser3e0f731
 
lecture2.ppt
lecture2.pptlecture2.ppt
lecture2.pptImXaib
 

Similar a Dbms chapter v (20)

Dmbs chapter vi
Dmbs chapter viDmbs chapter vi
Dmbs chapter vi
 
ER Modeling.ppt
ER Modeling.pptER Modeling.ppt
ER Modeling.ppt
 
2. Relational_Data_Model_Keys_10b.pptx
2. Relational_Data_Model_Keys_10b.pptx2. Relational_Data_Model_Keys_10b.pptx
2. Relational_Data_Model_Keys_10b.pptx
 
Sameer
SameerSameer
Sameer
 
"Python Dictionary: The Key to Efficient Data Storage, Manipulation, and Vers...
"Python Dictionary: The Key to Efficient Data Storage, Manipulation, and Vers..."Python Dictionary: The Key to Efficient Data Storage, Manipulation, and Vers...
"Python Dictionary: The Key to Efficient Data Storage, Manipulation, and Vers...
 
Free video lectures for mca
Free video lectures for mcaFree video lectures for mca
Free video lectures for mca
 
ER diagram slides for datanase stujdy-1.pdf
ER diagram slides for datanase stujdy-1.pdfER diagram slides for datanase stujdy-1.pdf
ER diagram slides for datanase stujdy-1.pdf
 
ER Digramms by Harshal wagh
ER Digramms by Harshal waghER Digramms by Harshal wagh
ER Digramms by Harshal wagh
 
Summary data modelling
Summary data modellingSummary data modelling
Summary data modelling
 
Exploiting web search engines to search structured
Exploiting web search engines to search structuredExploiting web search engines to search structured
Exploiting web search engines to search structured
 
DBMS Notes: DDL DML DCL
DBMS Notes: DDL DML DCLDBMS Notes: DDL DML DCL
DBMS Notes: DDL DML DCL
 
Relational Model on Database management PPT
Relational Model on Database management PPTRelational Model on Database management PPT
Relational Model on Database management PPT
 
ikd312-03-design
ikd312-03-designikd312-03-design
ikd312-03-design
 
Unit 02 dbms
Unit 02 dbmsUnit 02 dbms
Unit 02 dbms
 
Python
PythonPython
Python
 
Handout#09
Handout#09Handout#09
Handout#09
 
Unit 04 dbms
Unit 04 dbmsUnit 04 dbms
Unit 04 dbms
 
lecture2.ppt
lecture2.pptlecture2.ppt
lecture2.ppt
 
lecture2.ppt
lecture2.pptlecture2.ppt
lecture2.ppt
 
Dictionaries.pptx
Dictionaries.pptxDictionaries.pptx
Dictionaries.pptx
 

Más de Bala Ganesh

Dbms chapter iii
Dbms chapter iiiDbms chapter iii
Dbms chapter iiiBala Ganesh
 
Flip flop& RAM ROM
Flip flop& RAM ROMFlip flop& RAM ROM
Flip flop& RAM ROMBala Ganesh
 
Chap iii-Logic Gates
Chap iii-Logic GatesChap iii-Logic Gates
Chap iii-Logic GatesBala Ganesh
 
Chap ii.BCD code,Gray code
Chap ii.BCD code,Gray codeChap ii.BCD code,Gray code
Chap ii.BCD code,Gray codeBala Ganesh
 
Software testing
Software testingSoftware testing
Software testingBala Ganesh
 
Software Requirements
Software RequirementsSoftware Requirements
Software RequirementsBala Ganesh
 
Comp 111chp iv vi
Comp 111chp iv viComp 111chp iv vi
Comp 111chp iv viBala Ganesh
 
Comp 107cep iii,iv,v
Comp 107cep iii,iv,vComp 107cep iii,iv,v
Comp 107cep iii,iv,vBala Ganesh
 
Wdf 222chp iii vi
Wdf 222chp iii viWdf 222chp iii vi
Wdf 222chp iii viBala Ganesh
 
Ch03-Software Engineering Model
Ch03-Software Engineering ModelCh03-Software Engineering Model
Ch03-Software Engineering ModelBala Ganesh
 

Más 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 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
 
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
 
Wdf22chp 1
Wdf22chp 1Wdf22chp 1
Wdf22chp 1
 
Ch03-Software Engineering Model
Ch03-Software Engineering ModelCh03-Software Engineering Model
Ch03-Software Engineering Model
 

Último

80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...Nguyen Thanh Tu Collection
 
Single or Multiple melodic lines structure
Single or Multiple melodic lines structureSingle or Multiple melodic lines structure
Single or Multiple melodic lines structuredhanjurrannsibayan2
 
SOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning PresentationSOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning Presentationcamerronhm
 
Unit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxUnit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxVishalSingh1417
 
How to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptxHow to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptxCeline George
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfagholdier
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...Poonam Aher Patil
 
REMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxREMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxDr. Ravikiran H M Gowda
 
Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)Jisc
 
Interdisciplinary_Insights_Data_Collection_Methods.pptx
Interdisciplinary_Insights_Data_Collection_Methods.pptxInterdisciplinary_Insights_Data_Collection_Methods.pptx
Interdisciplinary_Insights_Data_Collection_Methods.pptxPooja Bhuva
 
Fostering Friendships - Enhancing Social Bonds in the Classroom
Fostering Friendships - Enhancing Social Bonds  in the ClassroomFostering Friendships - Enhancing Social Bonds  in the Classroom
Fostering Friendships - Enhancing Social Bonds in the ClassroomPooky Knightsmith
 
Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseAnaAcapella
 
ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.MaryamAhmad92
 
Graduate Outcomes Presentation Slides - English
Graduate Outcomes Presentation Slides - EnglishGraduate Outcomes Presentation Slides - English
Graduate Outcomes Presentation Slides - Englishneillewis46
 
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...Nguyen Thanh Tu Collection
 
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptxMaritesTamaniVerdade
 
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptxHMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptxmarlenawright1
 
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxSKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxAmanpreet Kaur
 
Google Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptxGoogle Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptxDr. Sarita Anand
 

Último (20)

80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
 
Single or Multiple melodic lines structure
Single or Multiple melodic lines structureSingle or Multiple melodic lines structure
Single or Multiple melodic lines structure
 
SOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning PresentationSOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning Presentation
 
Unit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxUnit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptx
 
How to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptxHow to setup Pycharm environment for Odoo 17.pptx
How to setup Pycharm environment for Odoo 17.pptx
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...
 
REMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptxREMIFENTANIL: An Ultra short acting opioid.pptx
REMIFENTANIL: An Ultra short acting opioid.pptx
 
Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)
 
Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024
 
Interdisciplinary_Insights_Data_Collection_Methods.pptx
Interdisciplinary_Insights_Data_Collection_Methods.pptxInterdisciplinary_Insights_Data_Collection_Methods.pptx
Interdisciplinary_Insights_Data_Collection_Methods.pptx
 
Fostering Friendships - Enhancing Social Bonds in the Classroom
Fostering Friendships - Enhancing Social Bonds  in the ClassroomFostering Friendships - Enhancing Social Bonds  in the Classroom
Fostering Friendships - Enhancing Social Bonds in the Classroom
 
Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please Practise
 
ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.
 
Graduate Outcomes Presentation Slides - English
Graduate Outcomes Presentation Slides - EnglishGraduate Outcomes Presentation Slides - English
Graduate Outcomes Presentation Slides - English
 
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
 
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
 
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptxHMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
HMCS Vancouver Pre-Deployment Brief - May 2024 (Web Version).pptx
 
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptxSKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
SKILL OF INTRODUCING THE LESSON MICRO SKILLS.pptx
 
Google Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptxGoogle Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptx
 

Dbms chapter v

  • 1. Subject Name Code Credit Hours Database System COMP 219 3 Chapter V
  • 2. Subject Name Code Credit Hours Database System COMP 219 3 Keys • It is used to uniquely identify entities within a given entityset or a relationship set. • Keys in Entity set: • (i) Primary Key: – It is a key used to uniquely identify an entity in the entity set. – E,g, eno,rno,dno etc…
  • 3. Subject Name Code Credit Hours Database System COMP 219 3 Keys • Super Key: • It is a set of one or more attributes that allow us to uniquely identify an entity in the entity set. Among them one must be a primary key attribute. • E.G.. Eid (primary key) and ename together can be identify an entity in entity set.
  • 4. Subject Name Code Credit Hours Database System COMP 219 3 Keys • Candidate key: • They are minimal super keys for which no proper subset is a superkey. • E.g.. Ename and eaddr can be sufficient to identify an employee in employee set. • {eid} and {ename,eaddr} – Candidate keys
  • 5. Subject Name Code Credit Hours Database System COMP 219 3 FOREIGN -----------------------Keys • An attribute which makes a reference to an attribute of another entity type is called foreign key
  • 6. Subject Name Code Credit Hours Database System COMP 219 3 Key  E.g… eid Ename eaddr dno dnamedno dloc Employee – E1 Dept – E2 Foreign Ke
  • 7. Subject Name Code Credit Hours Database System COMP 219 3 Domain • A range of values can be defined for an attribute and is called as Domain of that attribute. • E.g.. Age – attribute A • Domain (A)= {1,2,….100}
  • 8. Subject Name Code Credit Hours Database System COMP 219 3 Keys in Relationship set: • Case 1: If the relationship set R has no attributes, then the set of attributes Primarykey(E1) U Primarykey(E2) U Primarykey (n) Case2: If the relationship set R has attributes, then the set of attributes,
  • 9. Subject Name Code Credit Hours Database System COMP 219 3 Keys in Relationship set Primarykey(E1) U Primarykey(E2) U Primarykey (n)U{a1,a2,…an} describes an individual relationship in set R. In both cases, Primarykey(E1) U Primarykey(E2) U Primarykey (n) forms a superkey for a relationship set.