Re: Does Codd's view of a relational database differ from that ofDate&Darwin?[M.Gittens]

From: Alexandr Savinov <savinov_at_host.com>
Date: Tue, 07 Jun 2005 13:15:53 +0200
Message-ID: <42a581fb$1_at_news.fhg.de>


Tony Andrews schrieb:

> Alexandr Savinov wrote:
> <SNIP>
> 

>>In order to understand why do we need tables and what
>>is their role consider the following example. Instead of one wide table
>>for all types of objects we are tought to introduce several more special
>>tables with only a smaller subset of columns. Such tables will have less
>>rows. However, then we might want to inroduce even more specialized
>>tables and so on. Finally we get a large number of tables each with a
>>relatively small number of rows. Interestingly, we can continue this
>>process and get tables with no rows at all! Thus theoretically we can
>>express our semantics without rows by using only tables. One simple
>>conclusion is that "data semantics can be expressed by tables rather
>>than only by rows (in tables)". It is very strong and somewhat
>>surprising result.
> 
> 
> You are not kidding!
> 
> 

>>In such an approach we do not need rows because
>>anything can be modelled by means of tables. Such a model is ugly from
>>relational point of view (although we simply followed an advice to
>>decompose tables) however it is interesting from theoretical point of
>>view (with big consequences).
> 
> 
> Which part of the decomposition process reduces 1 row to 0 rows?  I
> must have missed that part...

I'll try to exlain using another example (but I am not sure if it is necessary taking into account your apriori negative predisposition). This example is especially illustrative for those who absolutely trusts RM.

How can you model a tree of items? There are two major alternatives: 1. Create a table with folders and a table with items. Each folder and each item has a field which specifies its parent folder. 2. Craate one table for each folder and store all items belonging to this folder in this table. There exist as many tables as we have folders.

Conclusion: This example demonstrates that tables have the same semantic load as normal records, i.e., they should be treated not only as a structural element but also as means for representing data semantics. Addding/removing tables changes the model semantics rather than only its structure.

Problem: A good model should somehow take this into account and provide facilities for representing and manipulating data semantics in at least these two forms.

Solution: I think before we can describe this item it is necessary to accept the first two (it does not make sense to solve a problem if it is not accepted as a problem).

Comment: Any data modeller with enough practical experience may draw this conclusion and formulate this problem - we can express our data semantics by means of tables but the relational model does not provide good means for representing and manipulating it. In other words, tables should be treated as normal entities with special (organizing) role with respect to other entities. The above example shows how rows are converted into tables and vice versa. In extreme case we might represent everything by tables only however, it is difficult in relational model because it is not intended to solve such problems.

-- 
alex
http://conceptoriented.com
Received on Tue Jun 07 2005 - 13:15:53 CEST

Original text of this message