Database Reference
In-Depth Information
Notice that in the transition system of M U of the host program (Program 1) we
consider the case when M U receives the answer from M R just in time and without
error.
The significant transitions in the computation system of M U , for the synchro-
nization of M U , are denoted by the symbol
in Fig. 6.3 , while the two horizontal
red lines are the time-synchronization instances.
6.2.1 The Categorial Approach to SQL Embedding
The synchrony conversations, for a given source host program P , between M U and
M R , described by the transition diagram in Fig. 6.3 , represent the execution of the
embedding (of the compiled SQL statements). The states of the machines are pro-
gressively enumerated from their initial states st( 0 )
S U , st ( 0 )
S R , w.r.t. a de-
terministic transition system TrS
P ) (in Definition 37 ). We can abstract
this deterministic transition system by forgetting the instruction addresses, that is,
by substituting the transitions ((j, st(i)),(k,f (st(i))))
=
(S P ,
∈→ P by the simple state-
transitions (st(i),f (st(i)))
∈→ P .
Let ATrS U = 2 (S PU ), P ) be an abstracted deterministic transition sys-
tem obtained from an execution of the program P on a host machine M U , with
π 2 (S PU )
S U the set of its internal states progressively enu-
merated from 0 (initial state) to the last N th state (end of this program) and
ATrS R =
={
st(i)
|
0
i
N
}⊆
P ) be the deterministic abstracted transitions system ob-
tained from the execution of the program P on an RDB machine M R , represented
in Fig. 6.3 , Sect. 6.2 . The most significant parts of the TrS (in what follows, we will
use this simplified abstracted transition system) of the M R , underlined in Fig. 6.3
by delimited intervals from diagram on the left (signed by
2 (S PR ),
) and right sides) are
the following:
1. Variable binding. It transforms an Application Plan into an arrow in RA .
The transition st (k)
λIn ER (Out U (st(j)))
st (k
ATrS R that corresponds to
the binding of bounded variables in the variable-binding operators of the called
Application Plan.
The Bind module during the compilation of the original source host program
P generates the Application Plans for each SQL statement in P , which are the
“variable-binding” RA arrows: it means that instead of the concrete operators of
Σ RA algebra, the constants (i.e., values) used for such operators are here substi-
tuted by the bounded variables. Only when the M U calls an Application Plan,
by passing the triple (n, 0 ,L) with the list L of values for this n th plan, then
the bounded variables of these value-binding operators are substituted (variable
binding) with the values in L , and hence these operators become the operators of
Σ RA algebra, and the Application Plan becomes exactly an arrow in RA .
2. Execution. By an application of the evaluation functor Eval
+
1 )
:
RA
DB .
f n
st (m)
The transition st (k
+
1 )
ATrS R , m
k
+
3 ,n
1, which cor-
responds to the composition of transactions f n =
RETURN
Out R
Ap n , where
DEC ) n , and
Ap n =
P n
(t 4
Search WWH ::




Custom Search