grr @ google groups for not showing me that this had already been
answered...
On Apr 2, 10:04 am, bob84123 wrote:
> You probably want to check out
> select_related:http://docs.djangoproject.com/en/dev/ref/models/querysets/#id4
>
> On Apr 1, 7:00 am, Federico Capoano wrote:
>
>
>
> > Hello to al
You probably want to check out select_related:
http://docs.djangoproject.com/en/dev/ref/models/querysets/#id4
On Apr 1, 7:00 am, Federico Capoano wrote:
> Hello to all,
>
> has been a while i've been wondering how to optimize Django's queries
> to the database, for example by setting it to use JO
> * select_related
> * only
> * extra
You also might be interested in "anotate" and "aggregate"
http://docs.djangoproject.com/en/dev/topics/db/aggregation/
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to dja
What about this solution to generate static files?
http://superjared.com/projects/static-generator/
On Apr 1, 12:49 am, Rolando Espinoza La Fuente
wrote:
> On Wed, Mar 31, 2010 at 5:22 PM, Federico Capoano
>
> wrote:
> > Thanks,
>
> > how many things i've learnt today, to optimize the number
Very cool, if the database won't be hit often and I manage to use the
new template caching functionality added to Django 1.2 the result will
be really performant.
Thank you very much, I save these info on caching for future
reference.
On Apr 1, 12:49 am, Rolando Espinoza La Fuente
wrote:
> On
On Wed, Mar 31, 2010 at 5:22 PM, Federico Capoano
wrote:
> Thanks,
>
> how many things i've learnt today, to optimize the number and length
> of query by using:
>
> * select_related
> * only
> * extra
>
> Do you think the performance gain is worth the work?
Yes. Specially in loops where you have:
Thanks,
how many things i've learnt today, to optimize the number and length
of query by using:
* select_related
* only
* extra
Do you think the performance gain is worth the work?
And I've a curiosity more to ask:
If I use the cache framework, once the results are cached the will the
database
On Wed, Mar 31, 2010 at 3:30 PM, Federico Capoano
wrote:
> Hello to all,
>
> has been a while i've been wondering how to optimize Django's queries
> to the database, for example by setting it to use JOIN to retrieve
> foreign keys instead of multiple selects.
>
> for example if I have a blog objec
Hello to all,
has been a while i've been wondering how to optimize Django's queries
to the database, for example by setting it to use JOIN to retrieve
foreign keys instead of multiple selects.
for example if I have a blog object that has a category foreign key
and I write in a template
{{ blog.c
9 matches
Mail list logo