Database Reference
In-Depth Information
3.
an indicated dimension;
STRUCTURE
(table_name.attr_name(value) ->
table_name.attr_name(value) -> ...
table_name.attr_name(value))
IN VERSION version_name
[VERSION FROM start_date
[TO end_date]]
4.
an indicated dimension instance.
The result of an object evolution query is the
history of the evolution of a specified object. This
history includes a DW version derivation tree and
metadata describing the structure of the object in
each of the retrieved DW versions.
An object evolution query is expressed by
means of the SHOW EVOLUTION OF clause,
followed by keywords specifying the type of an
object whose evolution is to be retrieved. Similarly
as for a version query, the set of keywords includes:
ATTRIBUTE, LEVEL TABLE, FACT TABLE,
DIMENSION, DIMENSION ... INSTANCE.
An object evolution query can address either all
existing DW versions or some versions. The set
of DW versions being queried can be constrained
by means of the VERSION FROM start_date [TO
end_date] clause. Its meaning is exactly the same
as for a version query.
Below we describe the syntax of each of the
aforementioned four types of an object evolution
query and illustrate the queries with examples.
For example, the below query searches for DW
versions in which in base version R_June : (1) di-
mension Location is composed of three hierarchi-
cally connected levels Shops Cities Regions ,
as specified in the INSTANCE OF EXACT
STRUCTURE clause, (2) the instance of dimen-
sion Location is defined on attributes Shops.
shop_name , Cities.city_name , and Regions.
reg_name , and (3) the dimension instance has the
following structure Auchan Warsaw Central .
Keyword EXACT causes that only dimension
instances whose structure is exactly as specified
in the query are considered. Since the VERSION
FROM clause was omitted, the query will address
all existing DW versions. Notice that the dimen-
sion, the level tables and their attributes could
change their names in other DW versions. In this
case their equivalents in other DW versions will
also be considered by the query.
OEQ1. Evolution of an attribute
The general syntax of the query is shown below.
The name of an attribute whose evolution is to be
retrieved follows the ATTRIBUTE keyword. The
attribute belongs either to a level or a fact table.
The name of this table is specified in clause FROM
{LEVEL|FACT} TABLE table_name.
SHOW VERSIONS HAVING
DIMENSION Location
INSTANCE OF EXACT STRUCTURE
(Shops.shop_name('Auchan') ->
Cities.city_name('Warsaw') ->
Regions.reg_name('Central'))
IN VERSION 'R_June'
SHOW EVOLUTION OF
ATTRIBUTE attribute_name
FROM {LEVEL|FACT} TABLE table_name
IN VERSION version_name
[VERSION FROM start_date
[TO end_date]]
Object Evolution Query
An object evolution query allows to retrieve the
evolution of:
1.
an indicated attribute of a fact or a level
table;
For example, the below query retrieves the
evolution history of attribute called amount in table
Sales , in base version R_February . Notice that a
2.
an indicated fact or level table;
Search WWH ::




Custom Search