On 12/3/10 1:55 PM, Jacek Kałucki wrote: > Użytkownik Paul McNett napisał: >> The cursor requery is precisely where the datastructure would change. > > Sorry, but I can't see such place. > Could you show me it please?
If someone hasn't set biz.DataStructure explicitly, then it comes from the cursor. The cursor defines DataStructure in the storeFieldTypes() segment, which happens during the cursor.requery() process. > I think, the only time the data structure changes is on the fly > database structure change, but it's rather reason for raising an > exception, I suppose. I happen to agree that the data structure should never change. But if it happens to change, we need to reinstantiate the Record object. > BTW, I see that you set DataStructure in the various ways: > 1) ac.DataStructure = self.DataStructure > 2) ac._dataStructure = self._dataStructure > I think, that first method is safer, but second is quicker. It depends on the context, which is better. If you want to quickly set the underlying attribute without firing off side-effects in the property setter, use #2. Otherwise, use #1. Paul _______________________________________________ Post Messages to: [email protected] Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev Searchable Archives: http://leafe.com/archives/search/dabo-dev This message: http://leafe.com/archives/byMID/[email protected]
