Database Reference
In-Depth Information
Here, as follows, we will permit the general case of updating with minimal side-
effects as well in the following two cases: Deletion and Insertion trough views.
The Update trough views is a combination of Deletion and, successively, of In-
sertion of updated information. Consequently, it will be considered successively in
the section on operational semantics for database mapping systems. In that section,
we will consider the trees of LTS that have a root in a modified database of a given
database mapping graph G . Such process trees are of two kinds: one is based on
forward propagation in the graph G that begins in the root database of LTS in which
new tuples (such trees can be infinite as well) are inserted; another is based on the
backward propagation from the root database of LTS in which a number of tuples
are deleted.
The process tree for updates of a given root database is then the composition of
the deletion (backward) tree (updated tuples are deleted) and of the insertion tree
(new updated tuples are inserted in this root database).
7.2.1 Deletion by Minimal Side-Effects
α (
=
B
B
In a deletion minimization, the input is a database B
with its
model α , a query q B i ( x i ) ,aview V = q B i ( x i ) B , and a set of tuples to be deleted
t V .
The view side-effect minimization is an algorithm for providing a set
) of a schema
B
B in
order to minimize
|
V
|
such that for the same query executed over updated database
B =
B
\
B (which is another model of database schema
B
) the obtained view is
\
V
t) .
In other words, we wish to find a set of tuples in B whose removal will delete t
while minimizing the number of other tuples deleted from the view V .
We can define this view deletion translation (VDT) as follows:
(
V
α (
Definition 49
Given a view V
=
q B ( x )
B of a database B
=
B
) (i.e., a model
of the schema
B
) and a deletion request
t , where t V , we say that a database
deletion
B causes the deletion of t from V when
applied to database B . More formally, let V =
B is a translation for
t if
q B ( x )
B be the new view, obtained
from the minimally updated database B =
α 1 (
) where α 1
B
\
B
=
B
is the new
V be the actual deleted set of tuples (the
updated model of
B
, and let
V
=
V
\
view deletions induced by
B ). We say that
B is a VDT for
t if t
V .
We denote the update of a model of
B
induced by VDT for
t over a sin-
M P n
gle view V by a transition α ====
α 1 , where P n is a sequential composi-
tion of RA arrows in the Application Plan considered as a program of catego-
rial machine M RC which executes the deleting of tuples in
.
From Proposition 30 in Sect. 6.2.2 , this transition corresponds to the natural trans-
formation η P n :
B of the schema
B
α α 1
DB Sch (G( B )) ) such that
(an arrow in Int(G(
B
))
α (
α 1 (
f D =
) , defined by Corollary 17 and specified in Exam-
ple 34 as an arrow in DB , is obtained from 'DELETE...' SQL statements used to
delete the tuples in
η P n (
B
)
:
B
)
B
B .
Search WWH ::




Custom Search