Re: Can relvars be dissymetrically decomposed? (vadim and x insight demanded on that subject)

From: Cimode <>
Date: 17 Jul 2006 12:39:37 -0700
Message-ID: <>

erk wrote:
> Cimode wrote:
> > [snip]
> > > > [snip]
> > > > For instance, if you consider the function F(X) = A(X) and you add
> > > > the value B to F(X), you are basically doing a translation making a new
> > > > function T(X) = F(X) + B = A(X) + B In this case, the result of adding
> > > > B to the function can be expressed (characterized) as a mathematical
> > > > translation (jumping from F(X) to T(X)). It says a lot about the
> > > > function F(X) behavior and may help describe it better over time.
> > >
> > > But F isn't changing. You're creating a new function, not changing an
> > > existing one. Assuming the expression F(X)+B makes sense, T has the
> > Now that's finally getting interesting... If I follow your reasoning
> > that would mean that once an INSERT is done, there would be necessarily
> > a new relation resulting from the INSERT operation performed?
> Well, the INSERT does an assignment after evaluating a relational
> expression - so doing an INSERT to a relvar R is the same as assigning
> to R the result of a relational expression involving R's current value.
I see your point. Lets try to formulate this differently... Suppose a relation R1 on which a single tuple is added. Let's consider there 10 tuples identified as R1(1), R1(2)...R1(10) ..R1 would then be expressed as

R1 = R1(1) UNION R1(2) UNION R1(2).......UNION R1(10) Now let's consider a *candidate* tuple (candidate as valid for insertion in terms of uniqueness, constraints respect, and NON NULL) added called S (for the moment let's not assume it is already a value of R1). The point that seems quite clear to me is that the result of the INSERT produces a new relation..Look below

The insert would be expressed as
R1(1) UNION R1(2) UNION R1(2).......UNION R1(10) UNION S S being NON NULL
it would be equivalent to
instead of
else it would be in contradiction with S being NON NULL

Furthermore, as a result of the operation S becomes R2(11) but not R1(11) which would be coherent with the analogy of a translation producing a new function.

> So the "new relation" you speak of is a new relation value, which is
> (as the very last step) assigned to variable R.
I am not convinced that a value added (tuple) is actually a value that is already a part of the initial relation unless it is a NULL value (not SQL NULL but a NULL tuple having no impact on the initial relation R1)
A similar reasoning could be applied to DELETE operations.

> Note that constraints complicate this - the assignment to R can fail
> because of database constraint violations. The evaluation of the
> expression can (unless decent type-checking is used) fail if it's not a
> valid value of type TYPE(R).
I see your point but I am not worried about typing. Let's assume that all candidate tuples for INSERT/DELETE are valid.

> > > > The
> > > > challenge of this thread is to do a similar effort on relations. For
> > > > instance, an interesting question raised would be: is an INSERT
> > > > operation equivalent to a translation in relational perspective?
> > I rephrase then : is an INSERT operation equivalent to a translation in
> > relational perspective resulting in a new relation?
> Any relational expression produces a relation value. If that's what you
> mean by the "new relation," then yes. If it's an UPDATE/INSERT/DELETE,
> that value is then assigned to the relvar, so the relvar has a new
> value - maybe that's what you mean.
Let's forget relvar and relvalue for the moment and focus on the relation (I should have called this thread accordingly). The question is that if one considers that the INSERT of a new tuple is the possibility for the relvar to hold a new value does it hold it for relation R1 or does it hold for a new relation R2. The answer seems clear to me.

> > > > Overall, how does a relation R1 *changes* when an INSERT, UPDATE,
> > > > DELETE operation is made on it? Characterizing such change would help
> > > > describe better relations themselves.
> > Are operations in general performed on relations create new relations.?
> Expressions (relational or otherwise) evaluate to values, which in the
> case of relational expressions are relations. "Create new" doesn't have
> much meaning in that context.
At abstract level of reasoning, I am not convinced that relations can *only* be characterized by their values or operations. I do not feel confortable with *create new* concept because it is not really and idea of creating a new instance but a whole new relation.

Suppose for instance R1 constitute a domain on which values can be drawn. It necessarily has a limited number of values. Don't you think adding a new value changes fundamentally the nature of the R1 defined domain and therefore is possible if and only if a new domain and a new relation R2 are created?

> - erk
Received on Mon Jul 17 2006 - 21:39:37 CEST

Original text of this message