Resiliency To New Data Requirements

From: Neo <neo55592_at_hotmail.com>
Date: 2 Aug 2006 09:55:54 -0700
Message-ID: <1154537754.724909.69430_at_p79g2000cwp.googlegroups.com>



These series of posts compare the impact on existing schema/data/queries in RMDB and dbd solutions as a result of adapting to new data requirements in one particular example. The example is based on following article:
http://www.intelligententerprise.com/db_area/archives/1999/991105/online2.jhtml;jsessionid=4J3MNANICW05WQSNDLRCKHSCJUNN2JVN

The example models/creates/represents/stores (which is preferred?) John and Mary who are employees. They belong to the finance and safety dept respectively. Their salaries are 10,000 and 20,000 respectively. Note that currently, dbd doesn't implement functions such as NOT, min, max, avg, sum, total, etc in it's select statements so this example will be limited to queries without them.

RMDB's initial implementation:
CREATE TABLE employee (emp#, name, dept, salary); INSERT INTO employee VALUES (123, john, finance, 10000); INSERT INTO employee VALUES (456, mary, safety, 20000);

// Following query returns Mary
SELECT * FROM employee WHERE (dept = "safety") AND (salary = 20000);

DBD's initial implementation:
(new '123 'emp#)
(new '456 'emp#)

(new 'finance 'dept)
(new 'safety 'dept)

(new '10000 'salary)
(new '20000 'salary)

(new 'john 'employee)
(new 'mary 'empolyee)

(create john emp# 123)
(create john dept finance)
(create john salary 10000)

(create mary emp# 456))
(create mary dept safety)
(create mary salary 20000)

(; Following query returns Mary)
(and (select employee instance *) (select * dept safety) (select *
salary 20000))

In the next post, a new data requirement (unknown initially) will be added to see its impact on existing schema/data/query on above RMDB and dbd solutions. Received on Wed Aug 02 2006 - 18:55:54 CEST

Original text of this message