Re: Decline of Science: Computer Science and Databases
Date: Mon, 04 Nov 2002 08:52:28 +0200
Message-ID: <3DC6192B.447EAED0_at_atbusiness.com>
Carl,
> I would be even more interested to see some complex
> querying and view examples but I haven't found any
> on a quick glance.
I am not very familiar with the documentation but I think they have some example programs here:
http://docs.alphora.com/DUGApplicationTutorial.html
> I would be especially interested to see, how you handle
> table inheritance in your querying approach.
That would not be "me", but "them" handling it ;-)
The concept of table inheritance does not exist (at least in the same sense). There is only datatype inheritance (which is different from table inheritance).
Dataphor is guided by the works of Date and Darwen (see www.thethirdmanifesto.com).
Complex queries? Give me an example of a complex query and I'll show how it is experssed in "D4", if I can.
Meanwhile you can look at my latest posting in the thread "Practical Benefits of the Relational Model".
regards,
Lauri
>
> public ObjectSet undefinedExtent() {
> Query q = db.query();
> q.descend("name").constrain("db").like();
> return q.execute();
> }
>
> public ObjectSet callBackByInterface() {
> Query q = db.query();
> q.constrain(Fast.class);
> q.constrain(new Evaluation() {
> public void evaluate(Candidate candidate) {
> candidate.include(
> ((Fast) candidate.getObject()).getSpeed() > 1000
> );
> }
> });
> return q.execute();
> }
>
> interface Fast {
> int getSpeed();
> }
>
> public ObjectSet callBackRegularExpression() {
> Query q = db.query();
> Query qName = q.descend("name");
> final Pattern pattern = Pattern.compile("*4o*");
> qName.constrain(new Evaluation() {
> public void evaluate(Candidate candidate) {
> candidate.include(pattern.matcher(
> ((String) candidate.getObject())).matches()
> );
> }
> });
> return q.execute();
> }
>
> public ObjectSet dualClass() {
> Query q = db.query();
> q.constrain(Consultant.class).or(q.constrain(Coach.class));
> q.descend("salary").constrain(new Double(200000)).greater();
> return q.execute();
> }
>
> public ObjectSet executeAnyNode() {
> Query q = db.query();
> q.constrain(Person.class);
> Query qContact = q.descend("contact");
> return qContact.execute();
> }
-- ________________________________________________________________ Lauri Pietarinen, Senior Consultant, Databases AtBusiness Communications Oyj, Kaapeliaukio 1, FIN-00180 Helsinki tel. +358-9-2311 6632, mob. +358-50-594 2011, fax +358-9-2311 6601 http://www.atbusiness.com, email: lauri.pietarinen_at_atbusiness.com _____________________________________________________________________Received on Mon Nov 04 2002 - 07:52:28 CET