Re: Demo: Modelling Cost of Travel Paths Between Towns

From: Neo <neo55592_at_hotmail.com>
Date: 3 Dec 2004 16:20:58 -0800
Message-ID: <4b45d3ad.0412031620.3f811ca3_at_posting.google.com>


> One of the basic properties of an RDBMS is that there can be
> underlying schema changes with no effect on existing code..

Below script demonstrates that XDb2's queries (similar to code) are resilient to changes in "schema" regardless of what things are represented. Please show RM's equivalent/similar query that demonstrates similar resiliency. Having stated that you are paid for your time and are a professional, try to avoid NULLs and duplicate data. If you are able to do that we can then represent additional new things and see if the original queries continue to work.

// XDb2's initial query to find things named john with age property // "SELECT %.age & %.name=john;"

// Martian with no name or age

CREATE *martian.cls = thing; // Create a martian class
CREATE *;                    // Create a thing
CREATE it.cls = martian;     // Classify it as a martian

// Martian with multiple names
CREATE *;                    // Create a thing
CREATE it.cls = martian;     // Classify it as a martian
CREATE it.name = +john;
CREATE it.name = +luke;

// Thing with multiple classes and multiple ages CREATE *plutonian.cls = thing;
CREATE *;

CREATE it.cls = martian;
CREATE it.cls = plutonian;
CREATE it.name = +john;
CREATE it.age = +10;
CREATE it.age = +"-3.14";

// Two Venutians with same name and age
CREATE *venutian.cls = thing;

CREATE *;

CREATE it.cls = venutian;
CREATE it.name = +john;
CREATE it.age = +very old;

CREATE *;

CREATE it.cls = venutian;
CREATE it.name = +john;
CREATE it.age = +very old;

// Execute original query
// (still works regardless of things represented) SELECT %.age & %.name=john; Received on Sat Dec 04 2004 - 01:20:58 CET

Original text of this message