[Zope] newbie q: howto get easy edit functionality on a database table for endusers, with input-restrictions?

Reinoud van Leeuwen reinoud@xs4all.nl
Tue, 11 Dec 2001 13:58:22 +0100 (CET)


> Hi. I'm trying to run Zope on FreeBSD 4.x-STABLE, with little success
> so far. :(

Well I've not encountered FreeBSD specific problems until now..

> What I need to know most is if Zope can support a database application
> with a sort of meta-definition of the database structure, so I can
> easily create definitions of forms (that are to be filled in by an
> end-user) in  form-configuration files. 
> In those form-configuration files, field and input-restrictions should
> be  listed for any given table/view of/to the database.
> After that I need an engine to parse those form-configuration files
> into an HTML window that actually allows editing of the database
> content..

What you need is an easily accessible dictionary. Most RDBMSes have 
dictionaties in their system tables which store some information about 
column types, referential constraints and allowed formats for fields.
Some even store extended information like description of fields and tables, 
headers for reports or forms and some even things like font definitions for 
input fields and headers...
Some systems allow you to store error messages in multiple languages in the 
database (which get selected based on the language setting from the 
connecting database client)

So generally, some of the information is already in the database. If the 
rest is not there already, you can add it yourself with some extra table 
definitions. (my choice would be to keep it in the database, because I do 
not like to split it from the rest of the information that is already 
there. Some people like to store it in (include) files for their client 
application.
I think there must be some dictionary things out there on the Internet...

So far, not very Zope specific. 

To use such a thing in Zope you will have to generally do:
- extract the meta information from the database
- have a generic routine that generates reports or forms
- have a generic way of errorhandling (because the logic is in the 
database, the errors will be reported from there and you will have to 
present them to the end-user)

I think step 2 can be done with a product like formulator and a little 
Python logic. The rest I am still figuring out myself ";-)

> In short, I need a replacement for Microsoft Access ;-)

You *can* use Access as a database backend (using ODBC), but some people 
still argue whether Access can be called a multi-user RDBMS ";-)

> Question: can zope do this, and if so, where is it documented?

I think some parts are available, but a general layer for something like 
this would add to the general acceptance of Zope in enterprise enviroments..
(or is it just that I want it really badly? ";-)

> PS a reporting engine (a-la M$ Access) would come in handy very much,
> too.

That should be part of such a product...


Reinoud