Hi All, I'm experimenting with ZSQL Methods and want to assign a ZClass to te result object. I've read that 'in the future' it wil be possible to do that. But.. Is it possible todo this already or has anyone a solution to do this another way? Greetings Ralph
I'm experimenting with ZSQL Methods and want to assign a ZClass to te result object. I've read that 'in the future' it wil be possible to do that. But..
Is it possible todo this already or has anyone a solution to do this another way?
Check out the Advanced tab on your ZSQL Method. Hmm. I wrote something related to this on this list not too long ago, but I can't seem to find it. Anyway, there's a howto on zope.org about Result objects and another on direct traversal of SQL results. One of those or the Zope Book chapter on SQL access (towards the end) should tell you how to assign a class to a Result object. (The online help for the ZSQL Advanced tab may be of some moderate use, too.) --jcc
Ralph vd Houdt wrote at 2003-3-26 11:55 +0100:
I'm experimenting with ZSQL Methods and want to assign a ZClass to te result object. I've read that 'in the future' it wil be possible to do that. But..
Is it possible todo this already or has anyone a solution to do this another way?
This is possible now. Your ZClass (used in this way) must not be persistent. This means you must uncheck the "include standard ZObject base class" (or something like that) when you construct your ZClass. Dieter
participants (3)
-
Dieter Maurer -
J Cameron Cooper -
Ralph vd Houdt