Re: S.O.D.A. database Query API - call for comments

From: Tobias Brox <tobiasb_at_suptra.org>
Date: Sat, 21 Jul 2001 18:00:54 GMT
Message-ID: <9cqukj$23r$1_at_tobiasb.invalid>


The java groups are removed from the follow-up.

In comp.databases Mikito Harakiri <nospam_at_newsranger.com> quoted:
> RDBs have little or no behavior.

Behaviour is a bit out of the scope of the database, it should ideally be in the code outside the database. Anyway it can often be needed.

Most of the advanced RDBMS'es supports triggers, generation of unique IDs and stored procedures. There is certainly a need for such. Unfortunately it's no standard for it, and it always looks very hacky to me.

Behaviour in the database can almost always be avoided by letting all access to the database go through some interface deamon running at the database server, or eventually some library routines, etc. Anyway, this is also a bit undesirable as it will take away the possibilities for using a standardized, powerful query languages directly from the applications.   

> OODBs sometimes
> pretend to have behavior (methods in the objects) but developers will
> find that as the application domain grows they will feel a pressure to
> move that behavior out of the database classes and into specific
> application classes.

I'd welcome the possibility of a standard way to store objects with methods in the database. It is certainly useful when:

  • Some work is needed to be done with a lot of data, just to return a simple value (like with aggregate functions like sum()). I think that in most cases, it will reduce overhead if the calculations can be performed within the database.
  • The same behaviour should apply regardless of which application (or user) that accesses the DB.
  • Some data might be calculated rather than extracted from the DB. A simple example, if the object has a length, it shouldn't matter for the end application which unit the length is in. It might use the methods length_in_cm, length_in_feet, length_in_inches or whatever.

There are probably tons of other examples.

This can also be solved by building some interface API for an particular database, but then again the power of the query language of the database is lost.

-- 
Tobias Brox - freelancer for hire!
Programming, system administration, etc
+47 98660706 / tobiasb_at_suptra.org
Received on Sat Jul 21 2001 - 20:00:54 CEST

Original text of this message