[Zope] Zope, database field formats, output format of queries

Dieter Maurer dieter@handshake.de
Wed, 24 Jan 2001 00:39:49 +0100 (CET)


Michael Schmidt writes:
 > On Mon, Jan 22, 2001 at 07:50:45PM +0100, Dieter Maurer wrote:
 > > What do you mean with a Zope based database?
 > > 
 > > If you mean an external database, look for the datatypes and
 > > restrictions, they support for column values. SQL 3 may
 > > give you some of what you want.
 > 
 > The wording of "Zope based database" may cause a misunderstanding, 
 > what I really meant was a database behind Zope or a database 
 > accessed through the interface of Zope.
That is what I have called an external database.
You may look what constraints the database allows to define
for field values.

 > > Whether internal or external, you can control what goes through
 > > Zope to your database. You will probably need External Methods to
 > > get the full Python power, see "python.org" for documentation
 > > about Pythons vast library.
 > > You will be especially interested in the "re" module.
 > > It implements (Perl style) regular expressions.
 > 
 > Do these also achieve error handling?
No.
They allow you to check whether the conditions are met.
You are free to decide what you do in this case.
The easiest thing is to raise an exception.
This results in a preconfigured error response, which
probably is not too useful.

You may look for a recent message to this list about
DTML contracts. It may give you most of what you want.


Dieter