What is the best way to manage MySQL connections? We’re using the mysqldba and frequently get the following errors when calling queryForResults:


  File "/home/djohnson/Zope-3.2.0/build/lib.linux-i686-2.4/zope/app/rdb/__init__.py", line 408, in queryForResults

    raise DatabaseException(str(error))

DatabaseException: Shouldn't load state for 0x01b3 when the connection is closed


We’re implementing in the following fashion:

self.connection = zapi.getUtility(IZopeDatabaseAdapter, name)

query = “select * from contacts”

results = queryForResults(self.connection,query)


It’s a local database on a machine with very little load, so connection issues should not be a regular problem.


David Johnson


Zope3-users mailing list

Reply via email to