Databases Reference
In-Depth Information
that we keep around, probably for auditing purposes. And we
have logfiles to take care of that.
The value of assertion table views on bi-temporal tables will
become clearer as this topic progresses. As we will see, assertion
table views are of particular interest to auditors.
For now, let's look at the SQL which will provide a view of all
assertions in our bi-temporal Policy table that have anything to
do with currently effective data. The version table view was a
view of all currently asserted versions. This assertion table view
is a view of all currently effective assertions.
CREATE VIEW V_Policy_Asr AS
SELECT oid, asr_beg_dt, asr_end_dt, eff_beg_dt,
eff_end_dt, client, type, copay
FROM Policy_AV
WHERE eff_beg_dt <ΒΌ Now()
AND Now() < eff_end_dt
This view filters out all rows that are not about what things
are like currently. It excludes past versions and future versions.
But this does not mean that the view is restricted to one row
per object. If this table ever contained erroneous data about
what things are currently like, that data will no longer be
asserted. It will be a past assertion about a current state of
affairs, and this view will include it. In addition, as we will see
in Chapter 12, an asserted version table may contain anticipated
data about what things are currently like. These will be future
assertions about a current state of affairs, and this view will
include those assertions as well.
Another aspect of the asymmetry between assertion time and
effective time is that two or more effective-time [intersecting]
versions of the same object, in shared assertion time, would vio-
late temporal entity integrity, making conflicting truth claims
wherever they shared an effective-time clock tick. Consequently,
the AVF includes code to prevent that from happening. But two
or more effective-time [intersecting] versions of the same object,
whose assertion time periods [exclude] one another, do not vio-
late temporal entity integrity. In fact, they violate no integrity
constraints, nor do they make conflicting truth claims. Rows
which share no clock ticks in assertion time are semantically
and truth-functionally isolated from one another. They are what
philosophers call incommensurable .
This is why this assertion table view must include both asser-
tion dates and effective dates in its projection.
In general, any asymmetry in what is otherwise a profoundly
symmetric set of concepts points to something important.
Search WWH ::




Custom Search