[DB-SIG] SqlObject Count
Ian Bicking
ianb@colorstudy.com
15 Feb 2003 18:26:43 -0600
On Sat, 2003-02-15 at 18:22, Erik Rivera Morales wrote:
> Hi!
>
> I am using SQLObject and it wrapper very good for me.
>
> do you know if has any method to count the registries (rows) of object
> (table) in use?
>
> or some idea to do it?
If you're not using transactions (i.e., objects tied to a connection),
and you are caching the objects fully, you can use
len(SomeTableClass._SO_instanceCache)
Of course that's accessing a private variable, so it may change in the
future.
--
Ian Bicking ianb@colorstudy.com http://colorstudy.com
4869 N. Talman Ave., Chicago, IL 60625 / 773-275-7241
"There is no flag large enough to cover the shame of
killing innocent people" -- Howard Zinn