Appendix A. Some Remarks on Relational Assignment

Change is not made without inconvenience

Samuel Johnson:

I claimed in Chapter 2 that the generic relational assignment—

R := rx

(where R is a relvar reference, or in other words a relvar name, syntactically speaking, and rx is a relational expression)—is logically equivalent to an assignment of the form:[157]

R := r - di

Well, actually, in Chapter 2 I used the keywords MINUS and UNION in place of the set difference symbol “–” and the set union symbol “∪”, respectively. In this appendix I find it more convenient to use the symbols. Other symbols I’ll be using include “∩” (set intersection), “⊆” (set inclusion) and “Ø” (the empty set). What’s more, in all of these contexts I ought really to be talking in terms of relations rather than general sets, but I propose to overlook this point of detail in what follows. Note: In Chapter 2 I also enclosed the subexpression rd (or r MINUS d, rather) in parentheses; in fact, however, no parentheses are needed, as we’ll soon see.

Be that as it may, let me now explain my notation in detail and elaborate on a few important points:

  • r is the value of R before the assignment (the “old” value of R); d is a set of tuples to be deleted from R (the “delete set”); and i is a set of tuples to be inserted into R (the “insert set”). Note: More precisely, d and i, like r, are really relations, and the sets of tuples I’m talking about are really the bodies of those relations. I’ll ignore this detail too in what ...

Get View Updating and Relational Theory now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.