On Sat, Sep 20, 2008 at 8:24 AM, Dieter Maurer <[EMAIL PROTECTED]> wrote:
> Tres Seaver wrote at 2008-9-19 09:33 -0400:
>> ...
>>There is a special 'STICKY' state which prevents ghostifying, but it
>>can't be set from Python code.  You could, however, set '_p_changed' on
>>the connection at the beginning of the method, and then delete it at the
>>end:  changed objects can't be ghostified.  E.g.:
>>   def my_method(self):
>>       self.connection._p_changed = 1
>>       try:
>>           self.sql()
>>           # now do the stuff which used to ghostify the connection
>>       finally:
>>           del self.connection._p_changed
> Are you sure that this works?
> According to my (not very clear) memory, "_p_changed" in a C level attribute
> (that is definite) which could be set to "1" from application level
> but not reset (that is not sure).
> --
> Dieter
> _______________________________________________

As I said in my previous post, I modified my test case to check if
this works, but I'm afraid it does not (i.e. I can still see two
connections at the database).


Marco Bizzarri
Zope maillist  -  Zope@zope.org
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-dev )

Reply via email to