On 7/31/07, Thomas Guettler <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> with SQLLogMiddleware (http://www.djangosnippets.org/snippets/344/) I see,
> that there are many statements executed twice in a single request.
>
> This links explains it:
> http://www.djangoproject.com/documentation/db-api/#caching-and-querysets
>
> How can I cache the result of MyModelClass.objects.get(id=...) at least
> for one request.

My guess is that using the session could achieve this for you.  A
"flash" persistence strategy would be better, but I'm unaware of one
provided out of the box.

-- 
Kevin

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to