Re: Using TEMP columns when the object is already in memory

[prev] [thread] [next] [Date index for 2004/05/12]

From: Perrin Harkins
Subject: Re: Using TEMP columns when the object is already in memory
Date: 19:37 on 12 May 2004
On Wed, 2004-05-12 at 14:36, Charles Bailey wrote:
> There's also the larger question of why someone's calling _init() when the 
> object already exists.

No one calls _init() directly, but if you do a search() or retrieve() or
anything else that returns CDBI objects it will call _init() internally
for each one.  That's why I put the single instance code there, at Tim
Bunce's suggestion.

> Prior to 0.96, they'd get an entirely new object 
> this way, and the two (or more) copies would "compete" for the DB row.

Yes, that's the problem that this change corrected.  It was too easy to
do this by accident before.

- Perrin

Re: Using TEMP columns when the object is already in memory
Perrin Harkins 19:37 on 12 May 2004

Generated at 11:34 on 01 Dec 2004 by mariachi v0.52