Re: Performance of large queries

[prev] [thread] [next] [Date index for 2004/07/15]

From: Tony Bowden
Subject: Re: Performance of large queries
Date: 09:35 on 15 Jul 2004
On Thu, Jul 15, 2004 at 10:27:05AM +0100, colm-cdbi@xxxxxxxxx.xx.xx wrote:
> AIUI the issue is not that you are getting objects back but that
> search() is internally implemented to only get ids and then each id has
> to go back to the database to do a seperate retrieve() for the
> 'Essential columns'.  It may very well be that this is no longer true, this
> is just what it seemed to do last time I looked.  I've often
> wondered if there was a way I was unaware of to (as an option) inject all the 'Essential'
> data directly into the objects or if there was any big reason this would
> be bad - can anyone shed any light on this?

If this is true it's a bug.

search() calls sql_Retrieve(), which is implemented as:

	__PACKAGE__->set_sql(Retrieve => <<'');
	SELECT __ESSENTIAL__
	FROM   __TABLE__
	WHERE  %s

The 'only fetching IDs' should only happen, therefore, if Essential ==
Primary. Making your Essential group bigger (e.g. to All) should speed
things up if you're going to need all the data anyway. 

Tony

Performance of large queries
cdbi-talk 07:00 on 15 Jul 2004

Re: Performance of large queries
colm-cdbi 09:27 on 15 Jul 2004

Re: Performance of large queries
Tony Bowden 09:35 on 15 Jul 2004

Re: Performance of large queries
colm-cdbi 09:58 on 15 Jul 2004

Re: Performance of large queries
Tony Bowden 10:04 on 15 Jul 2004

Re: Performance of large queries
Perrin Harkins 17:13 on 15 Jul 2004

Re: Performance of large queries
cdbi-talk 19:22 on 15 Jul 2004

Re: Performance of large queries
colm-cdbi 21:05 on 15 Jul 2004

Re: Performance of large queries
Tony Bowden 23:05 on 15 Jul 2004

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