SlideShare uma empresa Scribd logo
1 de 18
Unit – 4
Data Distribution Alternatives
Fragmentation
Horizontal Fragmentation
• Basic Requirement of Horizontal Fragmentation
1. Find out simple predicate Pr
2. Find out Minterm predicates M
3. Minterm selectivity sel(mi)
4. Access Frequencies acc(qi)
5. Access Frequencies Minterm acc(qi)
1/11/2017 2Prof. Dhaval R. Chandarana
Fragmentation Examples
• Example PROJECT table:
• PROJ:
PNO PNAME BUDGET LOC
P1 Instrumentation 150000 Montreal
P2 Database Develop 135000 New York
P3 CAD/CAM 250000 New York
P4 Maintenance 310000 Paris
1/11/2017 3Prof. Dhaval R. Chandarana
Predicates
• Predicates
• Appear in the WHERE clause of a query
• Important determiner of fragmentation
• Determine the composition of table fragments
• Let R(A1, A2, …, An) be a relation
• Ai is defined over a domain Di
• We say pi is a simple predicate if it is of the form
• Pi ʘ Value where ʘ ԑ { =, <, >, , , <> }
• Examples:
• PNAME = 'CAD/CAM'
• BUDGET > 200000
1/11/2017 4Prof. Dhaval R. Chandarana
Predicates
• Usually, multiple predicates are necessary to describe a selection of
rows in a relation
• Most Boolean combinations can be translated into conjunctive normal
form
• p1 ^ p2 ^ …^ pk
• We attempt to fragment tables according to selection (WHERE clause)
patterns
• A combination of predicates in conjunctive normal form is a Minterm
• Let a set of predicates on a relation be:
Pr = {p1, p2, …, pk }
1/11/2017 5Prof. Dhaval R. Chandarana
Minterms
• Let set of minterm predicates be
M = { m1, m2, …, mz }
where M = {mj | mj = ^(pn ԑ Pr) pn}
• Some property equivalences:
• For equality: !(attr = val) = (attr <> val)
• For inequality: !(attr > val) = (attr val)
• It is not necessary to duplicate predicates
• In minterms, one is sufficient
1/11/2017 6Prof. Dhaval R. Chandarana
Minterm Examples
• p1: LOC = 'Montreal'
• p2: LOC = 'New York'
• p3: LOC = 'Paris'
• p4: BUDGET > 200000
• p5: BUDGET <= 200000
• m1: LOC = 'New York' ^ BUDGET > 200000
• m2: LOC = 'New York' ^ BUDGET <= 200000
• m3: LOC = 'Paris' ^ BUDGET > 200000
• m4: LOC = 'Paris' ^ BUDGET <= 200000
• m5: LOC = 'Montreal' ^ BUDGET > 200000
• m6: LOC = 'Montreal ' ^ BUDGET <= 200000
1/11/2017 7Prof. Dhaval R. Chandarana
Minterm Properties
• Minterm selectivity
• Number of records that satisfy minterm
• sel(m1) = 1; sel(m2) = 1; sel(m4) = 0
• Access frequency by applications and users
• Q = {q1, q2, …, qq} is set of queries
• acc(q1) is frequency of access of query 1
1/11/2017 8Prof. Dhaval R. Chandarana
Primary Horizontal Fragmentation
• Using minterms and access frequency, one can generate a horizontal
fragmentation
• Suppose there are w fragments
• Then each relation fragment Ri is given by a formula Fi, where each
formula represents a minterm expression of predicates
Ri = ϭ Fi(R) where 1 <= i <= w
• Examples:
• PROJ1 = BUDGET<=200000 (PROJ)
• PROJ2 = BUDGET>200000 (PROJ)
1/11/2017 9Prof. Dhaval R. Chandarana
Algorithm for Determining Minterms
• Rule 1: fragment is partitioned into at least two parts that are
accessed differently by at least one application
• Definitions
• R - relation
• Pr - set of simple predicates
• Pr' - another set of simple predicates
• F - set of minterm fragments
1/11/2017 10Prof. Dhaval R. Chandarana
Algorithm for Determining Minterms
• Define set of inferences from the predicates
• Assume val1 and val2 are complimentary and complete the set of values:
• p1: att = val1
• p2: att = val2
• i1: (att = val1) => !(att = val2)
• i2: (att = val2) => !(att = val1)
• set of possible minterms
• m1: (att = val1) ^ (att = val2)
• m2: (att = val1) ^ !(att = val2)
• m3: !(att = val1) ^ (att = val2)
• m4: !(att = val1) ^ !(att = val2)
• m1 and m4 cannot be minterms because they contradict inferences
1/11/2017 11Prof. Dhaval R. Chandarana
Calculate Minterms for Table
PHORIZONTAL {
Pr' = COM_MIN(R, Pr)
determine set of minterms M
determine inference set I among Pr'
eliminate contradictory mi's according to I from M
eliminate subsumed minterms
what is left in M is horizontal fragmentation
}
1/11/2017 12Prof. Dhaval R. Chandarana
Example
Step 1: Identify relevant predicates
• p1: LOC = 'Montreal'
• p2: LOC = 'New York'
• p3: LOC = 'Paris'
• p4: BUDGET > 200000
• p5: BUDGET <= 200000
1/11/2017 13Prof. Dhaval R. Chandarana
Define Full Minterm Set
• m1: LOC = ‘Montreal’
• m2: LOC = ‘New York’
• m3: LOC = ‘Paris’
• m4: BUDGET > 200000
• m5: BUDGET <= 200000
• m6: LOC = ‘Montreal’ ^ LOC = ‘New York’
• m7: LOC = ‘Montreal’ ^ LOC = ‘Paris’
• m8: LOC = ‘Montreal’ ^ BUDGET > 200000
• m9: LOC = ‘Montreal’ ^ BUDGET <= 200000
• m10: LOC = ‘New York’ ^ LOC = ‘Paris’
• m11: LOC = ‘New York’ ^ BUDGET > 200000
• m12: LOC = ‘New York’ ^ BUDGET <= 200000
1/11/2017 14Prof. Dhaval R. Chandarana
Define Full Minterm Set
• m13: LOC = ‘Paris’ ^ BUDGET > 200000
• m14: LOC = ‘Paris’ ^ BUDGET <= 200000
• m15: BUDGET > 200000 ^ BUDGET <= 200000
• m16: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ LOC = ‘Paris’
• m17: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ BUDGET > 200000
• m18: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ BUDGET <= 200000
• m19: LOC = ‘Montreal’ ^ LOC = ‘Paris’ ^ BUDGET > 200000
• m20: LOC = ‘Montreal’ ^ LOC = ‘Paris’ ^ BUDGET <= 200000
• m21: LOC = ‘Montreal’ ^ BUDGET > 200000 ^ BUDGET <= 200000
• m22: LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET > 200000
• m23: LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET <= 200000
• m24: LOC = ‘New York’ ^ BUDGET > 200000 ^ BUDGET <= 200000
• m25: LOC = ‘Paris’ ^ BUDGET > 200000 ^ BUDGET <= 200000
1/11/2017 15Prof. Dhaval R. Chandarana
Define Full Minterm Set
• m26: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET >
200000
• m27: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET <=
200000
• m28: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ BUDGET > 200000 ^ BUDGET
<= 200000
• m29: LOC = ‘Montreal’ ^ LOC = ‘Paris’ ^ BUDGET > 200000 ^ BUDGET <=
200000
• m30: LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET > 200000 ^ BUDGET <=
200000
• m31: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET >
200000 ^ BUDGET <= 200000
1/11/2017 16Prof. Dhaval R. Chandarana
Define Inferences
• Inferences:
• p1 => ~p2 p3 => ~p1
• p1 => ~p3 p3 => ~p2
• p2 => ~p1 p4 => ~p5
• p2 => ~p3 p5 => ~p4
• Left with only:
• m1: LOC = ‘Montreal’ m8: LOC = ‘Montreal’ ^ BUDGET > 200000
• m2: LOC = ‘New York’ m9: LOC = ‘Montreal’ ^ BUDGET <= 200000
• m3: LOC = ‘Paris’ m12: LOC = ‘New York’ ^ BUDGET <= 200000
• m4: BUDGET > 200000 m13: LOC = ‘Paris’ ^ BUDGET > 200000
• m5: BUDGET <= 200000 m14: LOC = ‘Paris’ ^ BUDGET <= 200000
• After subsumption, only m8, m9, m11, m12, m13, m14 remain
1/11/2017 17Prof. Dhaval R. Chandarana
Actual Partitions
• The four actual partitions are: m9, m11, m12, m13
• The two partitions m8 and m14 have no data
PNO PNAME BUDGET LOC
P1 Instrumentation 150000 Montreal
P2 Database Develop 135000 New York
P3 CAD/CAM 250000 New York
P4 Maintenance 310000 Paris
1/11/2017 18Prof. Dhaval R. Chandarana

Mais conteúdo relacionado

Mais procurados

Fuzzy rules and fuzzy reasoning
Fuzzy rules and fuzzy reasoningFuzzy rules and fuzzy reasoning
Fuzzy rules and fuzzy reasoningVeni7
 
Flow control and error control
Flow control and error controlFlow control and error control
Flow control and error controlBHUVIJAYAVELU
 
Real Time communication System
Real Time communication SystemReal Time communication System
Real Time communication SystemAmit Ram Dubey
 
Forward and Backward chaining in AI
Forward and Backward chaining in AIForward and Backward chaining in AI
Forward and Backward chaining in AIMegha Sharma
 
Database, 3 Distribution Design
Database, 3 Distribution DesignDatabase, 3 Distribution Design
Database, 3 Distribution DesignAli Usman
 
Predicate calculus
Predicate calculusPredicate calculus
Predicate calculusRajendran
 
Directory and discovery services
Directory and discovery servicesDirectory and discovery services
Directory and discovery servicesRamchandraRegmi
 

Mais procurados (20)

Fuzzy rules and fuzzy reasoning
Fuzzy rules and fuzzy reasoningFuzzy rules and fuzzy reasoning
Fuzzy rules and fuzzy reasoning
 
Introduction to Application layer
Introduction to Application layerIntroduction to Application layer
Introduction to Application layer
 
Flow control and error control
Flow control and error controlFlow control and error control
Flow control and error control
 
Functional dependency
Functional dependencyFunctional dependency
Functional dependency
 
Distributed DBMS - Unit 1 - Introduction
Distributed DBMS - Unit 1 - IntroductionDistributed DBMS - Unit 1 - Introduction
Distributed DBMS - Unit 1 - Introduction
 
Point to-point protocol (ppp)
Point to-point protocol (ppp)Point to-point protocol (ppp)
Point to-point protocol (ppp)
 
5. protocol layering
5. protocol layering5. protocol layering
5. protocol layering
 
Real Time communication System
Real Time communication SystemReal Time communication System
Real Time communication System
 
Quality of Service
Quality of ServiceQuality of Service
Quality of Service
 
Ch04
Ch04Ch04
Ch04
 
Distributed database
Distributed databaseDistributed database
Distributed database
 
Quality of service
Quality of serviceQuality of service
Quality of service
 
Congestion control and quality of service
Congestion control and quality of serviceCongestion control and quality of service
Congestion control and quality of service
 
Xml processors
Xml processorsXml processors
Xml processors
 
Artificial Neural Network Topology
Artificial Neural Network TopologyArtificial Neural Network Topology
Artificial Neural Network Topology
 
Forward and Backward chaining in AI
Forward and Backward chaining in AIForward and Backward chaining in AI
Forward and Backward chaining in AI
 
Distributed DBMS - Unit 5 - Semantic Data Control
Distributed DBMS - Unit 5 - Semantic Data ControlDistributed DBMS - Unit 5 - Semantic Data Control
Distributed DBMS - Unit 5 - Semantic Data Control
 
Database, 3 Distribution Design
Database, 3 Distribution DesignDatabase, 3 Distribution Design
Database, 3 Distribution Design
 
Predicate calculus
Predicate calculusPredicate calculus
Predicate calculus
 
Directory and discovery services
Directory and discovery servicesDirectory and discovery services
Directory and discovery services
 

Mais de Gyanmanjari Institute Of Technology

Mais de Gyanmanjari Institute Of Technology (20)

WD - Unit - 7 - Advanced Concepts
WD - Unit - 7 - Advanced ConceptsWD - Unit - 7 - Advanced Concepts
WD - Unit - 7 - Advanced Concepts
 
WD - Unit - 4 - PHP Basics
WD - Unit - 4 - PHP BasicsWD - Unit - 4 - PHP Basics
WD - Unit - 4 - PHP Basics
 
WD - Unit - 3 - Java Script
WD - Unit - 3 - Java ScriptWD - Unit - 3 - Java Script
WD - Unit - 3 - Java Script
 
WD - Unit - 6 - Database Connectivity using PHP
WD - Unit - 6 - Database Connectivity using PHPWD - Unit - 6 - Database Connectivity using PHP
WD - Unit - 6 - Database Connectivity using PHP
 
WD - Unit - 5 - Session and State Management using PHP
WD - Unit - 5 - Session and State Management using PHPWD - Unit - 5 - Session and State Management using PHP
WD - Unit - 5 - Session and State Management using PHP
 
WD - Unit - 2 - HTML & CSS
WD - Unit - 2 - HTML & CSSWD - Unit - 2 - HTML & CSS
WD - Unit - 2 - HTML & CSS
 
WD - Unit - 1 - Introduction
WD - Unit - 1 - IntroductionWD - Unit - 1 - Introduction
WD - Unit - 1 - Introduction
 
OSV - Unit - 8 - Unix/Linux Operating System
OSV - Unit - 8 - Unix/Linux Operating SystemOSV - Unit - 8 - Unix/Linux Operating System
OSV - Unit - 8 - Unix/Linux Operating System
 
OSV - Unit - 10 - Approaches to Virtualization
OSV - Unit - 10 - Approaches to VirtualizationOSV - Unit - 10 - Approaches to Virtualization
OSV - Unit - 10 - Approaches to Virtualization
 
OSV - Unit - 9 - Virtualization Concepts
OSV - Unit - 9 - Virtualization ConceptsOSV - Unit - 9 - Virtualization Concepts
OSV - Unit - 9 - Virtualization Concepts
 
OSV - Unit - 7 - I/O Management & Disk scheduling
OSV - Unit - 7 - I/O Management & Disk schedulingOSV - Unit - 7 - I/O Management & Disk scheduling
OSV - Unit - 7 - I/O Management & Disk scheduling
 
OSV - Unit - 6 - Memory Management
OSV - Unit - 6 - Memory ManagementOSV - Unit - 6 - Memory Management
OSV - Unit - 6 - Memory Management
 
CNS - Unit - 10 - Web Security Threats and Approaches
CNS - Unit - 10 - Web Security Threats and ApproachesCNS - Unit - 10 - Web Security Threats and Approaches
CNS - Unit - 10 - Web Security Threats and Approaches
 
OSV - Unit - 5 - Deadlock
OSV - Unit - 5 - DeadlockOSV - Unit - 5 - Deadlock
OSV - Unit - 5 - Deadlock
 
OSV - Unit - 4 - Inter Process Communication
OSV - Unit - 4 - Inter Process CommunicationOSV - Unit - 4 - Inter Process Communication
OSV - Unit - 4 - Inter Process Communication
 
OSV - Unit - 3 - Concurrency
OSV - Unit - 3 - ConcurrencyOSV - Unit - 3 - Concurrency
OSV - Unit - 3 - Concurrency
 
OSV - Unit - 2 - Process and Threads Management
OSV - Unit - 2 - Process and Threads ManagementOSV - Unit - 2 - Process and Threads Management
OSV - Unit - 2 - Process and Threads Management
 
CNS - Unit - 8 - Key Management and Distribution
CNS - Unit - 8 - Key Management and DistributionCNS - Unit - 8 - Key Management and Distribution
CNS - Unit - 8 - Key Management and Distribution
 
CNS - Unit - 7 - Digital Signature
CNS - Unit - 7 - Digital SignatureCNS - Unit - 7 - Digital Signature
CNS - Unit - 7 - Digital Signature
 
CNS - Unit - 6 - Message Authentication Code
CNS - Unit - 6 - Message Authentication CodeCNS - Unit - 6 - Message Authentication Code
CNS - Unit - 6 - Message Authentication Code
 

Último

Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Dr.Costas Sachpazis
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduitsrknatarajan
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxAsutosh Ranjan
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Dr.Costas Sachpazis
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Bookingdharasingh5698
 
Introduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxIntroduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxupamatechverse
 
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...Call Girls in Nagpur High Profile
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...roncy bisnoi
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesPrabhanshu Chaturvedi
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...Call Girls in Nagpur High Profile
 
AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdfankushspencer015
 
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service NashikCall Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service NashikCall Girls in Nagpur High Profile
 
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...Christo Ananth
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingrknatarajan
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdfKamal Acharya
 
Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur EscortsRussian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSSIVASHANKAR N
 

Último (20)

Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
Sheet Pile Wall Design and Construction: A Practical Guide for Civil Engineer...
 
UNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular ConduitsUNIT-II FMM-Flow Through Circular Conduits
UNIT-II FMM-Flow Through Circular Conduits
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptx
 
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
Structural Analysis and Design of Foundations: A Comprehensive Handbook for S...
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
 
Introduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptxIntroduction and different types of Ethernet.pptx
Introduction and different types of Ethernet.pptx
 
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
 
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
Call Girls Pimpri Chinchwad Call Me 7737669865 Budget Friendly No Advance Boo...
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
 
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
(INDIRA) Call Girl Aurangabad Call Now 8617697112 Aurangabad Escorts 24x7
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and Properties
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
 
AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdf
 
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service NashikCall Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
Call Girls Service Nashik Vaishnavi 7001305949 Independent Escort Service Nashik
 
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
Call for Papers - Educational Administration: Theory and Practice, E-ISSN: 21...
 
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and workingUNIT-V FMM.HYDRAULIC TURBINE - Construction and working
UNIT-V FMM.HYDRAULIC TURBINE - Construction and working
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdf
 
Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur EscortsRussian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
Russian Call Girls in Nagpur Grishma Call 7001035870 Meet With Nagpur Escorts
 
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLSMANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
MANUFACTURING PROCESS-II UNIT-5 NC MACHINE TOOLS
 

Distributed DBMS - Unit - 4 - Data Distribution Alternatives

  • 1. Unit – 4 Data Distribution Alternatives Fragmentation
  • 2. Horizontal Fragmentation • Basic Requirement of Horizontal Fragmentation 1. Find out simple predicate Pr 2. Find out Minterm predicates M 3. Minterm selectivity sel(mi) 4. Access Frequencies acc(qi) 5. Access Frequencies Minterm acc(qi) 1/11/2017 2Prof. Dhaval R. Chandarana
  • 3. Fragmentation Examples • Example PROJECT table: • PROJ: PNO PNAME BUDGET LOC P1 Instrumentation 150000 Montreal P2 Database Develop 135000 New York P3 CAD/CAM 250000 New York P4 Maintenance 310000 Paris 1/11/2017 3Prof. Dhaval R. Chandarana
  • 4. Predicates • Predicates • Appear in the WHERE clause of a query • Important determiner of fragmentation • Determine the composition of table fragments • Let R(A1, A2, …, An) be a relation • Ai is defined over a domain Di • We say pi is a simple predicate if it is of the form • Pi ʘ Value where ʘ ԑ { =, <, >, , , <> } • Examples: • PNAME = 'CAD/CAM' • BUDGET > 200000 1/11/2017 4Prof. Dhaval R. Chandarana
  • 5. Predicates • Usually, multiple predicates are necessary to describe a selection of rows in a relation • Most Boolean combinations can be translated into conjunctive normal form • p1 ^ p2 ^ …^ pk • We attempt to fragment tables according to selection (WHERE clause) patterns • A combination of predicates in conjunctive normal form is a Minterm • Let a set of predicates on a relation be: Pr = {p1, p2, …, pk } 1/11/2017 5Prof. Dhaval R. Chandarana
  • 6. Minterms • Let set of minterm predicates be M = { m1, m2, …, mz } where M = {mj | mj = ^(pn ԑ Pr) pn} • Some property equivalences: • For equality: !(attr = val) = (attr <> val) • For inequality: !(attr > val) = (attr val) • It is not necessary to duplicate predicates • In minterms, one is sufficient 1/11/2017 6Prof. Dhaval R. Chandarana
  • 7. Minterm Examples • p1: LOC = 'Montreal' • p2: LOC = 'New York' • p3: LOC = 'Paris' • p4: BUDGET > 200000 • p5: BUDGET <= 200000 • m1: LOC = 'New York' ^ BUDGET > 200000 • m2: LOC = 'New York' ^ BUDGET <= 200000 • m3: LOC = 'Paris' ^ BUDGET > 200000 • m4: LOC = 'Paris' ^ BUDGET <= 200000 • m5: LOC = 'Montreal' ^ BUDGET > 200000 • m6: LOC = 'Montreal ' ^ BUDGET <= 200000 1/11/2017 7Prof. Dhaval R. Chandarana
  • 8. Minterm Properties • Minterm selectivity • Number of records that satisfy minterm • sel(m1) = 1; sel(m2) = 1; sel(m4) = 0 • Access frequency by applications and users • Q = {q1, q2, …, qq} is set of queries • acc(q1) is frequency of access of query 1 1/11/2017 8Prof. Dhaval R. Chandarana
  • 9. Primary Horizontal Fragmentation • Using minterms and access frequency, one can generate a horizontal fragmentation • Suppose there are w fragments • Then each relation fragment Ri is given by a formula Fi, where each formula represents a minterm expression of predicates Ri = ϭ Fi(R) where 1 <= i <= w • Examples: • PROJ1 = BUDGET<=200000 (PROJ) • PROJ2 = BUDGET>200000 (PROJ) 1/11/2017 9Prof. Dhaval R. Chandarana
  • 10. Algorithm for Determining Minterms • Rule 1: fragment is partitioned into at least two parts that are accessed differently by at least one application • Definitions • R - relation • Pr - set of simple predicates • Pr' - another set of simple predicates • F - set of minterm fragments 1/11/2017 10Prof. Dhaval R. Chandarana
  • 11. Algorithm for Determining Minterms • Define set of inferences from the predicates • Assume val1 and val2 are complimentary and complete the set of values: • p1: att = val1 • p2: att = val2 • i1: (att = val1) => !(att = val2) • i2: (att = val2) => !(att = val1) • set of possible minterms • m1: (att = val1) ^ (att = val2) • m2: (att = val1) ^ !(att = val2) • m3: !(att = val1) ^ (att = val2) • m4: !(att = val1) ^ !(att = val2) • m1 and m4 cannot be minterms because they contradict inferences 1/11/2017 11Prof. Dhaval R. Chandarana
  • 12. Calculate Minterms for Table PHORIZONTAL { Pr' = COM_MIN(R, Pr) determine set of minterms M determine inference set I among Pr' eliminate contradictory mi's according to I from M eliminate subsumed minterms what is left in M is horizontal fragmentation } 1/11/2017 12Prof. Dhaval R. Chandarana
  • 13. Example Step 1: Identify relevant predicates • p1: LOC = 'Montreal' • p2: LOC = 'New York' • p3: LOC = 'Paris' • p4: BUDGET > 200000 • p5: BUDGET <= 200000 1/11/2017 13Prof. Dhaval R. Chandarana
  • 14. Define Full Minterm Set • m1: LOC = ‘Montreal’ • m2: LOC = ‘New York’ • m3: LOC = ‘Paris’ • m4: BUDGET > 200000 • m5: BUDGET <= 200000 • m6: LOC = ‘Montreal’ ^ LOC = ‘New York’ • m7: LOC = ‘Montreal’ ^ LOC = ‘Paris’ • m8: LOC = ‘Montreal’ ^ BUDGET > 200000 • m9: LOC = ‘Montreal’ ^ BUDGET <= 200000 • m10: LOC = ‘New York’ ^ LOC = ‘Paris’ • m11: LOC = ‘New York’ ^ BUDGET > 200000 • m12: LOC = ‘New York’ ^ BUDGET <= 200000 1/11/2017 14Prof. Dhaval R. Chandarana
  • 15. Define Full Minterm Set • m13: LOC = ‘Paris’ ^ BUDGET > 200000 • m14: LOC = ‘Paris’ ^ BUDGET <= 200000 • m15: BUDGET > 200000 ^ BUDGET <= 200000 • m16: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ LOC = ‘Paris’ • m17: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ BUDGET > 200000 • m18: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ BUDGET <= 200000 • m19: LOC = ‘Montreal’ ^ LOC = ‘Paris’ ^ BUDGET > 200000 • m20: LOC = ‘Montreal’ ^ LOC = ‘Paris’ ^ BUDGET <= 200000 • m21: LOC = ‘Montreal’ ^ BUDGET > 200000 ^ BUDGET <= 200000 • m22: LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET > 200000 • m23: LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET <= 200000 • m24: LOC = ‘New York’ ^ BUDGET > 200000 ^ BUDGET <= 200000 • m25: LOC = ‘Paris’ ^ BUDGET > 200000 ^ BUDGET <= 200000 1/11/2017 15Prof. Dhaval R. Chandarana
  • 16. Define Full Minterm Set • m26: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET > 200000 • m27: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET <= 200000 • m28: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ BUDGET > 200000 ^ BUDGET <= 200000 • m29: LOC = ‘Montreal’ ^ LOC = ‘Paris’ ^ BUDGET > 200000 ^ BUDGET <= 200000 • m30: LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET > 200000 ^ BUDGET <= 200000 • m31: LOC = ‘Montreal’ ^ LOC = ‘New York’ ^ LOC = ‘Paris’ ^ BUDGET > 200000 ^ BUDGET <= 200000 1/11/2017 16Prof. Dhaval R. Chandarana
  • 17. Define Inferences • Inferences: • p1 => ~p2 p3 => ~p1 • p1 => ~p3 p3 => ~p2 • p2 => ~p1 p4 => ~p5 • p2 => ~p3 p5 => ~p4 • Left with only: • m1: LOC = ‘Montreal’ m8: LOC = ‘Montreal’ ^ BUDGET > 200000 • m2: LOC = ‘New York’ m9: LOC = ‘Montreal’ ^ BUDGET <= 200000 • m3: LOC = ‘Paris’ m12: LOC = ‘New York’ ^ BUDGET <= 200000 • m4: BUDGET > 200000 m13: LOC = ‘Paris’ ^ BUDGET > 200000 • m5: BUDGET <= 200000 m14: LOC = ‘Paris’ ^ BUDGET <= 200000 • After subsumption, only m8, m9, m11, m12, m13, m14 remain 1/11/2017 17Prof. Dhaval R. Chandarana
  • 18. Actual Partitions • The four actual partitions are: m9, m11, m12, m13 • The two partitions m8 and m14 have no data PNO PNAME BUDGET LOC P1 Instrumentation 150000 Montreal P2 Database Develop 135000 New York P3 CAD/CAM 250000 New York P4 Maintenance 310000 Paris 1/11/2017 18Prof. Dhaval R. Chandarana