+ All Categories
Home > Travel > Full Disjunction

Full Disjunction

Date post: 14-May-2015
Category:
Upload: atul-shridhar
View: 620 times
Download: 0 times
Share this document with a friend
Popular Tags:
17
Full Disjunctions Full Disjunctions Itzhak Fadida Itzhak Fadida Technion Israel Credits for this presentation are due to my colleague Benny Kimelfeld.
Transcript
Page 1: Full Disjunction

Full DisjunctionsFull Disjunctions

Itzhak FadidaItzhak FadidaTechnion Israel

Credits for this presentation are due to my colleague Benny Kimelfeld.

Page 2: Full Disjunction

Example – Planning a tourExample – Planning a tour

When we plan a tour we wish to have the maximal information to help us make the correct choices.

Page 3: Full Disjunction

Data Sources – Tourist InformationData Sources – Tourist Information

CountryClimate

Canadadiverse

Bahamastropical

UKtempera

te

ClimatesClimates

CountryCityHotelStars

CanadaToront

oPlaza4

CanadaLondo

nRamad

a3

BahamasNassauHilton

AccommodationsAccommodations

CountryCitySite

CanadaLondo

nAir Show

CanadaMount Logan

UKLondo

nBuckingha

m

UKLondo

nHyde Park

SitesSites

Page 4: Full Disjunction

Natural Join – Providing Natural Join – Providing MaximalMaximal Information Information

SELECTSELECT * * FROMFROM

((ClimatesClimates Natural JoinNatural Join AccommodationsAccommodations)) Natural JoinNatural Join SitesSites

Country

CityClimateHotelStars

Site

CanadaLondon

diverseRamada

3Air Show

Page 5: Full Disjunction

Natural Outer Join – Natural Outer Join – PreservingPreserving Information Information

SELECTSELECT * * FROMFROM

((ClimatesClimates Natural Outer JoinNatural Outer Join AccommodationsAccommodations))

Natural Outer JoinNatural Outer Join SitesSites

Country

CityClimateHotelStars

Site

CanadaToronto

diversePlaza4

CanadaLondon

diverseRamada

3Air Show

CanadaMount Logan

UKLondon

Buckingham

UKLondon

Hyde Park

UKtemperate

Bahamas

Nassau

TropicalHilton

Page 6: Full Disjunction

Tourist Example – Full DisjunctionsTourist Example – Full Disjunctions

SELECTSELECT * * FROMFROM

FD(FD(ClimatesClimates,, AccommodationsAccommodations,, Sites Sites))

Country

CityClimateHotelStars

Site

CanadaToronto

diversePlaza4

CanadaLondon

diverseRamada

3Air Show

CanadadiverseMount Logan

UKLondon

temperate

Buckingham

UKLondon

temperate

Hyde Park

Bahamas

NassautropicalHilton

Page 7: Full Disjunction

The Natural The Natural JoinJoin Operator Operator

CountryClimateCityHotelStarsSite

Climates Accommodations Sites

CountryClimateCanadadiverse

Bahamastropical

UKtemperat

e

Climates

CountryCityHotelStarsCanadaTorontoPlaza4CanadaLondonRamada3

BahamasNassauHilton

Accommodations

CountryCitySiteCanadaLondonAir Show

CanadaMount Logan

UKLondonBuckinghamUKLondonHyde Park

Sites

⋈ ⋈

CanadadiverseLondonRamad

a3Air

Show

A join tuple corresponds to a set of source tuples

Join consistentJoin consistent

ConnectedConnectedNo Cartesian product

CompleteCompleteOne tuple from each relation

Join consistentJoin consistent

ConnectedConnectedNo Cartesian product

CompleteCompleteOne tuple from each relation

Page 8: Full Disjunction

Natural Join Misses InformationNatural Join Misses Information

CountryClimate

Canadadiverse

Bahamastropical

UKtempera

te

ClimatesClimates

CountryCityHotelStars

CanadaToront

oPlaza4

CanadaLondo

nRamad

a3

BahamasNassauHilton

AccommodationsAccommodations

CountryCitySite

CanadaLondo

nAir Show

CanadaMount Logan

UKLondo

nBuckingha

m

UKLondo

nHyde Park

SitesSitesBahamas is not in SitesSites, so natural join misses it

Page 9: Full Disjunction

Natural Join Misses InformationNatural Join Misses Information

CountryClimate

Canadadiverse

Bahamastropical

UKtempera

te

ClimatesClimates

CountryCityHotelStars

CanadaToront

oPlaza4

CanadaLondo

nRamad

a3

BahamasNassauHilton

AccommodationsAccommodations

CountryCitySite

CanadaLondo

nAir Show

CanadaMount Logan

UKLondo

nBuckingha

m

UKLondo

nHyde Park

SitesSitesBahamas is not in SitesSites, so natural join misses it

Mount Logan is not in a city, hence missed

A looser notion of join is needed—one that enables joining tuples from some of the tables

A looser notion of join is needed—one that enables joining tuples from some of the tables

Page 10: Full Disjunction

Why and What is Full DisjunctionsWhy and What is Full Disjunctions??

The full-disjunction operation is a variation of the join operator that maximally combines join consistent tuples from connected relations, while preserving all information in the relations.

Page 11: Full Disjunction

An Example of a Full DisjunctionAn Example of a Full Disjunction

CountryClimateCanadadiverse

UKtemperate

ClimatesClimates

CountryCityHotelStarsCanadaTorontoPlaza4CanadaLondonRamada3

AccommodationsAccommodations

CountryCitySiteCanadaLondonAir Show

CanadaMount Logan

UKLondonBuckingham

SitesSites

CountryClimateCityHotelStarsSiteFD(R)

R

Page 12: Full Disjunction

An Example of a Full DisjunctionAn Example of a Full Disjunction

CountryClimateCanadadiverse

UKtemperate

ClimatesClimates

CountryCityHotelStarsCanadaTorontoPlaza4CanadaLondonRamada3

AccommodationsAccommodations

CountryCitySiteCanadaLondonAir Show

CanadaMount Logan

UKLondonBuckingham

SitesSites

CountryClimateCityHotelStarsSite

CanadadiverseTorontoPlaza4

FD(R)

R

Page 13: Full Disjunction

An Example of a Full DisjunctionAn Example of a Full Disjunction

CountryClimateCanadadiverse

UKtemperate

ClimatesClimates

CountryCityHotelStarsCanadaTorontoPlaza4CanadaLondonRamada3

AccommodationsAccommodations

CountryCitySiteCanadaLondonAir Show

CanadaMount Logan

UKLondonBuckingham

SitesSites

CountryClimateCityHotelStarsSite

CanadadiverseTorontoPlaza4

CanadadiverseLondonRamad

a3Air Show

FD(R)

R

Page 14: Full Disjunction

An Example of a Full DisjunctionAn Example of a Full Disjunction

CountryClimateCanadadiverse

UKtemperate

ClimatesClimates

CountryCityHotelStarsCanadaTorontoPlaza4CanadaLondonRamada3

AccommodationsAccommodations

CountryCitySiteCanadaLondonAir Show

CanadaMount Logan

UKLondonBuckingham

SitesSites

CountryClimateCityHotelStarsSite

CanadadiverseTorontoPlaza4

CanadadiverseLondonRamad

a3Air ShowCanadadiverse

Mount Logan

FD(R)

R

Page 15: Full Disjunction

An Example of a Full DisjunctionAn Example of a Full Disjunction

CountryClimateCanadadiverse

UKtemperate

ClimatesClimates

CountryCityHotelStarsCanadaTorontoPlaza4CanadaLondonRamada3

AccommodationsAccommodations

CountryCitySiteCanadaLondonAir Show

CanadaMount Logan

UKLondonBuckingham

SitesSites

CountryClimateCityHotelStarsSite

CanadadiverseTorontoPlaza4

CanadadiverseLondonRamad

a3Air ShowCanadadiverse

Mount Logan

UKtempera

te

London Buckingha

m

FD(R)

R

Page 16: Full Disjunction

An Example of a Full DisjunctionAn Example of a Full Disjunction

CountryClimateCanadadiverse

UKtemperate

ClimatesClimates

CountryCityHotelStarsCanadaTorontoPlaza4CanadaLondonRamada3

AccommodationsAccommodations

CountryCitySiteCanadaLondonAir Show

CanadaMount Logan

UKLondonBuckingham

SitesSites

CountryClimateCityHotelStarsSite

CanadadiverseTorontoPlaza4

CanadadiverseLondonRamad

a3Air ShowCanadadiverse

Mount Logan

UKtempera

te

London Buckingha

m

FD(R)

R

Page 17: Full Disjunction

Any Questions?


Recommended