On Wed, 2007-12-19 at 06:25 -0800, shabda wrote:
> Ah. I see this ticket has a patch. Any thing specific this is waiting
> for?
The patch attached to the ticket doesn't do anything useful. It's
exactly the same as doing the loop in your own code. If we're going to
add an update method, it shoul
Ah. I see this ticket has a patch. Any thing specific this is waiting
for? Since I was really hoping for something like this, any thing
specific I can help you with to close this? (I have not really looked
inside Django, but I may be able to help you test it?)
On Dec 19, 6:45 pm, Malcolm Tredinni
On Wed, 2007-12-19 at 05:35 -0800, shabda wrote:
> I have a QuerySet returned by a call like this
>
> foos = Foo.objects.filter(id__in = [1, 2, 3])
>
> Now I want to update each of these elements' attributes to a specific
> value. What I need to do is some thing like,
>
> for foo in foos:
>
I have a QuerySet returned by a call like this
foos = Foo.objects.filter(id__in = [1, 2, 3])
Now I want to update each of these elements' attributes to a specific
value. What I need to do is some thing like,
for foo in foos:
foo.price = 0
foo.save()
But this would make as many database
4 matches
Mail list logo