On Jun 16, 9:21 am, "Dan O'Keefe" <[email protected]> wrote: > On Tue, Jun 16, 2009 at 8:39 AM, Bob Silverberg > <[email protected]>wrote: > > > It seems to me that the main reason that one would use a query over a > > collection of objects is for performance - to save the cost of creating all > > of those objects. So if you already have a collection of objects, why would > > you want to convert them back to a query? It seems like you'd be losing > > functionality and not gaining anything in terms of performance. > > > What sort of things would you be looking to do with a query that you cannot > > do, or wouldn't choose to do, with a collection of objects? > > Unless I am mistaken, I was thinking it would be the other way around. If I > already have cached objects I use in other places, would be quicker to > convert to a query, versus a hit to the database. I know the TQL is cached > after the first hit, but a DB call versus converting it in memory. >
I think Bob meant that if you already have the array of objects, why convert it to a query? Why not just return the array of objects and use the array in your view? No conversion, no DB hit. Matt Williams --~--~---------~--~----~------------~-------~--~----~ Before posting questions to the group please read: http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer You received this message because you are subscribed to the Google Groups "transfer-dev" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/transfer-dev?hl=en -~----------~----~----~----~------~----~------~--~---
