[Zope] How do I use a Z Oracle Connection in a script?

J. Cone jcone@g8labs.com
Mon, 16 Jul 2001 16:28:27 +0100


Hello Dieter,

I am sorry to be so ignorant, but your second suggestion defeats me, so far.

In my script, I have the lines:

  db0=Shared.DC.ZRDB.Connection
  c=db0.cursor

which get me the errors:

  Error Type: NameError
  Error Value: Shared

Please tell me which binding to look in for Shared.

Thanks,
J. Cone.

At 14:12 14/07/01 +0200, Dieter Maurer wrote:
<snip>
>You have in fact two nested wrappers:
>
>  1. the database adapter, derived from "Shared.DC.ZRDB.Connection".
>
>     It is a persistent object stored in the ZODB.
>
>  2. the "db", a non-persistent wrapper around the
>     DB-API connection
>
>Call call a database adapter to get the "db" wrapper.
>The "db", then, has a product specific way to get at
>the DB-API connection. Look at the code in "Products/ZOracleDA/db.py".
>
>
>Dieter
>
>