Databases Reference
In-Depth Information
IntervalMatch magic
Because of the associative nature of the data model, and the dynamic nature of the
queries a QlikView user performs, interval-based dimensions cannot be "queried"
as one would with SQL-syntax queries. That's OK, since the associative engine can
also handle such dimensions, just with a different, associative-based, approach.
Let's see how.
Since the dimension value is dependent upon a time frame, the basic concept is that
the key field, through which the dimension is associated with the rest of the data
model, must be composed of both the dimension ID and a time element.
We refer to "time element" as the individual pieces into which an interval can be split.
The splitting of intervals means that one interval-based record in a table will be
converted to several element-based records. If, for instance, an interval encompasses
the equivalent of three time elements, the individual record will then be expanded
into three different records, one for each of the corresponding time elements.
Expanding the intervals
The IntervalMatch function splits discrete, numeric-based, intervals based on
two inputs:
• A table composed of two fields: one for the start of the interval and one for
the end of the interval
• A list of values representing the individual data points into which the
intervals will be split (the time element), according to their matching
All intervals must be closed, that is, they all must have an end value.
Let's look at a basic example to better illustrate the concept. Suppose we have the
following intervals table:
ID
Start
End
A
6
8
B
2
15
C
9
20
D
1
8
E
8
15
F
10
15
G
6
9
H
8
9
Search WWH ::




Custom Search