Anssi,
Thanks for your trouble, you were right, the problem was in my other code.
Regards,
P
Are you sure the leak is not in process_messages?
>
>
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-use
On May 28, 5:42 pm, pc wrote:
> I am stumped. I am trying process a lot of data (2 million records and
> up) and once I have a QuerySet, I immediately feed it to a
> queryset_iterator that fetched results in chunks of 1000 rows each. I
> use MySQL and the DB server is on another machine (so I don'
I am stumped. I am trying process a lot of data (2 million records and
up) and once I have a QuerySet, I immediately feed it to a
queryset_iterator that fetched results in chunks of 1000 rows each. I
use MySQL and the DB server is on another machine (so I don't think it
is MySQL caching).
I kick o
On 8/28/07, Tomas Kopecek <[EMAIL PROTECTED]> wrote:
...
> For me it could be more appropriate to change iterator() to do some
> slicing for me (by explicit LIMIT clause), maybe a small patch for our
> application. I understand, that changing it in general would be a bad
> design decision.
Ick.
James Bennett napsal(a):
> On 8/27/07, Jeremy Dunck <[EMAIL PROTECTED]> wrote:
>> QuerySet.iterator does what you want.
>
> I was going to follow up with a documentation link, but it appears we
> lost the documentation for QuerySet.iterator at some point. Opened a
> ticket
>
> In any case, Jerem
On 8/27/07, Jeremy Dunck <[EMAIL PROTECTED]> wrote:
> QuerySet.iterator does what you want.
I was going to follow up with a documentation link, but it appears we
lost the documentation for QuerySet.iterator at some point. Opened a
ticket
In any case, Jeremy's right: the "iterator" method returns
On 8/27/07, Tomas Kopecek <[EMAIL PROTECTED]> wrote:
> I've thought, that QuerySets whose are iterated does not allocate memory
> for all objects.
QuerySet.iterator does what you want.
QuerySet.__iter__ (the python method that is called from the for loop)
returns an iterator over the results of
There isn't much difference. Once you ennumerate,slice, or iterate a
queryset that's when the actual database query occurs. It will pull
in all matching object in order to save you additional queries.
Why not iterate in batches, by slicing the query? That way if you set
you step to say 100, yo
Hello,
I've thought, that QuerySets whose are iterated does not allocate memory
for all objects. But simple test shows otherwise. When I iterate through
SomeModel.objects.all() I get same memory consumption like with
list(SomeModel.objects.all()). It is very frustrating, because with test
datab
9 matches
Mail list logo