mirror of
https://github.com/django/django.git
synced 2025-10-31 09:41:08 +00:00
queryset-refactor: Fixed the case of calling update() on a model manager.
git-svn-id: http://code.djangoproject.com/svn/django/branches/queryset-refactor@7146 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
@@ -56,5 +56,12 @@ Multiple fields can be updated at once
|
||||
>>> d.value, d.another_value
|
||||
(u'fruit', u'peaches')
|
||||
|
||||
In the rare case you want to update every instance of a model, update() is also
|
||||
a manager method.
|
||||
|
||||
>>> DataPoint.objects.update(value='thing')
|
||||
>>> DataPoint.objects.values('value').distinct()
|
||||
[{'value': u'thing'}]
|
||||
|
||||
"""
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user