From: Martin Virtel <virtel@gm...> - 2002-03-04 07:18:00
my "Source" MiddleKit objects contain a "list of Visit" attribute referencing
several "Visit" objects. When I try to delete one of the "Source" objects from
the MySql store, MiddleKit retrieves the whole "Visit" table, presumably to
look up if there are some "Visit" objects that belong to the "Source" object
I'm trying to delete:
SQL 0009. 2002-03-03 06:34:31 select visitId,start,end,found,new,sourceId from Visit ;
This takes forever, the "Visit" table contains about 30.000 objects, and only
about 1-2% of them ever belong to the same "Source" object. Wouldn't it be
better to query only relevant objects, something like:
'select visitId,start,end,found,new,sourceId from Visit where sourceId = %s'
or is there some special reason the whole table needs to be read that I don't
-- Martin Virtel
aim / yahoo messenger mvftd
tel. +49 177 242 2889
Get latest updates about Open Source Projects, Conferences and News.