Database Reference
In-Depth Information
that can be used to specify mappings. In Chapter 21 , we shed light on these problems
by providing characterizations of the most common classes of mappings in terms of the
structural properties they satisfy.
17.2 Manipulating schema mappings
The second type of problems we look at in the metadata management framework (some-
times called model management) is more operational in nature. We look at operations on
mappings themselves, i.e., operations that let us build new mappings from existing ones.
Some operations that have been proposed include match, merge, compose and invert. Here
we concentrate on composition and inversion, as these are the key operators for under-
standing schema evolution .
We now describe the intuition behind the composition operator, and show how it can be
used in practice to solve some metadata management problems. Let
M 12 be the mapping
given in Chapter 1 , which is used to translate information from a source schema R 1 ,
consisting of relations GEO(city, country, population) and FLIGHT(source,
destination, airline, departure) ,
into a target schema R 2 , consisting of
relations
ROUTES(flight#, source, destination) ,
INFO FLIGHT(flight#,
departure time, arrival time, airline)
and
SERVES(airline, city,
country, phone) . Mapping
M 12 is specified by using st-tgds:
FLIGHT ( src , dest , airl , dep )
−→
f #
arr ( ROUTES ( f # , src , dest )
INFO FLIGHT ( f # , dep , arr , airl ))
FLIGHT ( city , dest , airl , dep )
GEO ( city , country , popul )
−→
phoneSERVES ( airl , city , country , phone )
FLIGHT ( src , city , airl , dep )
GEO ( city , country , popul )
−→
phoneSERVES ( airl , city , country , phone ) .
Assume that schema R 2 has to be updated into a new target schema R 3 consisting of the
following relations:
INFO AIRLINE(airline, city, country, phone, year)
This relation has information about cities served by airlines: for example, it may
have a tuple (AirFrance, Santiago, Chile, 5550000, 1982) , indicating that
AirFrance serves Santiago, Chile, since 1982, and its office there can be reached at
555-0000.
INFO JOURNEY(flight#, source, departure time, destination,
arrival time, airline)
This relation has information about routes served by several airlines. For each flight,
this relation stores the flight number ( flight# ), source, departure time, destination,
arrival time and the name of the airline.
Search WWH ::




Custom Search