mirror of
https://github.com/django/django.git
synced 2025-09-26 12:09:19 +00:00
Updated the tests.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8268 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
dc14b29fb3
commit
c763f26173
3 changed files with 8 additions and 2 deletions
|
@ -282,6 +282,7 @@ DoesNotExist: Restaurant matching query does not exist.
|
|||
# The update() command can update fields in parent and child classes at once
|
||||
# (although it executed multiple SQL queries to do so).
|
||||
>>> Restaurant.objects.filter(serves_hot_dogs=True, name__contains='D').update(name='Demon Puppies', serves_hot_dogs=False)
|
||||
1
|
||||
>>> r1 = Restaurant.objects.get(pk=r.pk)
|
||||
>>> r1.serves_hot_dogs == False
|
||||
True
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue