[Zope3-dev] Re: ZopeX3 with sqlos

Sidnei da Silva sidnei at awkly.org
Mon Jul 5 17:42:23 EDT 2004


On Mon, Jul 05, 2004 at 05:27:57PM -0400, Derrick 'dman' Hudson wrote:
| I modified the SQLObjectContainer class (in sqlos/container/__init_.py) adding
| the line
|     classNames = ('Person',)
| where Person is the name of the sqlos:factory configured in ZCML.

You could just as well have subclassed SQLObjectContainer.

| 
| I also modified sqlobject/dbconnection.py.  Around line 434, I added
| the line
|     self.query = 'SELECT * FROM acl'
| right above where it says
|     if dbconn.debug:
|         dbconn.printDebug(rawconn, self.query, 'Select')
|     self.dbconn._executeRetry(self.rawconn, self.cursor, self.query)
| 
| 'ACL' is the name of the already-existing table I wanted to display
| the contents of.  I kept seeing invalid SQL statements being
| generated.  I don't know if that is a result of something else I set
| wrong or a bug in sqlobject's trunk revision.  This hack let me
| sidestep that issue for the time being.

Yuck! What database you are using? I suspect you are using the
Postgres adapter with a different database.


-- 
Sidnei da Silva <sidnei at awkly.org>
http://awkly.org - dreamcatching :: making your dreams come true
http://www.enfoldsystems.com
http://plone.org/about/team#dreamcatcher

<radix> continuations make me want to hurt you, dash
<dash> continuations made me want to hurt a lot of people


More information about the Zope3-dev mailing list