Re: How to represent a total-and-exclusive relation into a relational database

From: Neo <neo55592_at_hotmail.com>
Date: 18 Jan 2005 14:43:58 -0800
Message-ID: <1106088238.828860.288770_at_z14g2000cwz.googlegroups.com>


// Create items in directory to classify things.
(CREATE *employe.item ~in = dir)
(CREATE *intern.item ~in = dir)
(CREATE *freelancer.item ~in = dir)
(CREATE *gender.item ~in = dir)
(CREATE *college.item ~in = dir)
(CREATE *expertise.item ~in = dir)

// Create employe John, an intern from MSU.
(CREATE *john.cls = employe)
(CREATE john.cls = intern)
(CREATE john.gender = +male)
(CREATE john.college = +MSU)

// Create employe Mary, a freelancer
// who is an expert in C++, RMDBs and SQL
(CREATE *mary.cls = employe)
(CREATE mary.cls = freelancer)
(CREATE mary.gender = +female)
(CREATE mary.expertise = +"C++")
(CREATE mary.expertise = +RMDBs)
(CREATE mary.expertise = +SQL)

// Find employes that know SQL.
// Finds Mary.
(SELECT %.cls=employe & %.expertise=SQL)
Received on Tue Jan 18 2005 - 23:43:58 CET

Original text of this message