Re: weird behavior in select_related

2011-01-30 Thread Ramiro Morales
On Sun, Jan 30, 2011 at 7:27 AM, Miguel Araujo wrote: > I didn't know that, that's why it was happening. I didn't post my models, as > I wasn't sure that would help. Btw, it's documented behavior: http://docs.djangoproject.com/en/1.2/ref/models/querysets/#select-related -- Ramiro Morales --

Re: weird behavior in select_related

2011-01-30 Thread Miguel Araujo
I didn't know that, that's why it was happening. I didn't post my models, as I wasn't sure that would help. Thanks for your help Daniel, Miguel Araujo @maraujop 2011/1/28 Daniel Roseman > On Saturday, January 22, 2011 1:38:22 PM UTC, maraujop wrote: >> >> Hi everyone, >> >> I have been wo

Re: weird behavior in select_related

2011-01-28 Thread Daniel Roseman
On Saturday, January 22, 2011 1:38:22 PM UTC, maraujop wrote: > > Hi everyone, > > I have been working on reducing DB queries in my project with great > results. But I have realized that select_related in one of my models doesn't > preload all the ForeignKeys and OneToOneFields, it preloads 3 out

Re: weird behavior in select_related

2011-01-28 Thread Miguel Araujo
Hi, Please anyone confirm if this is normal, so I can report it or not. Thanks, regards Miguel Araujo @maraujop 2011/1/22 Miguel Araujo > Hi everyone, > > I have been working on reducing DB queries in my project with great > results. But I have realized that select_related in one of my

weird behavior in select_related

2011-01-22 Thread Miguel Araujo
Hi everyone, I have been working on reducing DB queries in my project with great results. But I have realized that select_related in one of my models doesn't preload all the ForeignKeys and OneToOneFields, it preloads 3 out of 5. Actually the 3 preloaded are ForeignKeys and the other 2 are OneToOn