Re: Nearest Common Ancestor Report (XDb1's $1000 Challenge)

From: Neo <neo55592_at_hotmail.com>
Date: 19 May 2004 20:03:18 -0700
Message-ID: <4b45d3ad.0405191903.4950d9fb_at_posting.google.com>


> > In XDb1's data model type, class and domain are the same thing.
>
> I treat types, classes and domains as three different things.
>
> A class is a set of individual items, events
> or notions from the real world that have enough attributes
> in common to warrant treating them as individual items from one set.

Agreed. In XDb1, any thing in the db can become a class. Thus t1 becomes a class of t2 when user enter 't2 isa t1'.

> A domain is the complete collection of allowable values for an attribute of
> individual members of a class.

In RM, the attributes of a new record are stipulated by the table design. In XDb1, a new thing can have any number of attributes including none (user code has to stipulate otherwise). As you stated, in RM, a record's attribute's value comes from a domain stipulated by the table design. In XDb1, a thing can be related to any other thing as a value. For example, t1 (john) can be related to t2 (35) as a value via 'john is 35'. t2 can have any number of classes. If t2 is 35, it should have the classes age and integer. If t2 is 'thirty-five', it should have the classes age and word. In the statement 't1 is t2', t2 can have any class. If user code limits t2 from a certain class, then it would be similar to a domain. Thus, I misspoke earlier. Class and domain are related but not equal.

> a datatype as a superset of many domains.
> The domain for all integers is the same as the datatype
> integer. The domain for attribute "age (in years)" of the class "employee"
> is a subset of the integer domain.

Suppose, car is the class of car1. Car1 has the attribute color. The attribute's value can be from the domain containing red and green. Would data type be red, green and blue (assume these are all the colors)? Or does data type include more things including '*&#xyzPN'? Would a color domain delcared as char(5) have a different data type than when declared as char(6)? Is there a difference between "type" and "data type"? It seems to me that "data type" has a dual meaning, one on which is related to hardware storage specifics? In reality, colors have nothing to do with char, integer or float. But when stored in most dbs they could have those data types. Where are the theorists :) Received on Thu May 20 2004 - 05:03:18 CEST

Original text of this message