[Zope-dev] any ADO planned suppor t??

Brian Lloyd Brian@digicool.com
Wed, 13 Oct 1999 11:48:16 -0400


> ... are there plans for ADO support from Zope in the future??
> >
> > Darn, As much as I want to build with Zope, I move fast and
> > furiosly with
> > .ASP,
> > hope that ADO is considered.....

There are no plans to support ADO in the way I believe you are
thinking of it (e.g., using ADO objects in the way you would
from an .asp page). Zope takes a fairly fundamentally different
approach to things like data access than ASP. A core design goal
of Zope is to provide a structured object environment that 
encourages the separation of content and logic rather.

In Zope, rather than having a bunch of templates that contain
content, code, database queries and possibly sensitive db login
information all mixed up together, you effective build an object
oriented interface to your data. For example, lets say a simple
app just gets employee info from a back end db. In Zope, you
might:

  o create a folder 'MyApp'

  o add a db connection to the folder

  o add an SQLMethod that uses that connection called 'GetEmployees',
    using a query that gets all employees

  o add a report ('report.html') that acts as the UI for the app.


What you have done, in effect, is created an "object" ("MyApp")
with a "method" ("GetEmployees") which your content managers
can call (in report.html) without knowing or caring about SQL,
databases, etc. The dtml in the report can be pretty simple:

    <ol>
    <dtml-in GetEmployees>
      <li><dtml-var name> ...
    </dtml-in>
    </ol>


The important point is that from a Zope development point of
view, it really doesn't make much difference what db you are
using - you would approach the app building process in the
same basic way. You don't have to know or care about the api
of the specific database in use - if you have a Zope DA for
that db, you can treat it like any other.

Hopefully this explains our point of view on why exposing a 
specific api (even a fairly decent one like ADO) for use directly 
in DTML a la ASP is unlikely. That said, it would probably be 
quite trivial for someone to implement an ADO-based DA for Zope
- though I don't think that's the question you were asking...


Brian Lloyd        brian@digicool.com
Software Engineer  540.371.6909              
Digital Creations  http://www.digicool.com