mirror of
https://github.com/django/django.git
synced 2025-10-24 06:06:09 +00:00
queryset-refactor: Merged changed from trunk up to [6463].
git-svn-id: http://code.djangoproject.com/svn/django/branches/queryset-refactor@6466 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
@@ -952,7 +952,7 @@ Example::
|
||||
If you pass ``in_bulk()`` an empty list, you'll get an empty dictionary.
|
||||
|
||||
``iterator()``
|
||||
~~~~~~~~~~~~
|
||||
~~~~~~~~~~~~~~
|
||||
|
||||
Evaluates the ``QuerySet`` (by performing the query) and returns an
|
||||
`iterator`_ over the results. A ``QuerySet`` typically reads all of
|
||||
@@ -1371,11 +1371,6 @@ equivalent::
|
||||
Entry.objects.filter(blog__id=3) # __exact is implied
|
||||
Entry.objects.filter(blog__pk=3) # __pk implies __id__exact
|
||||
|
||||
.. note::
|
||||
Because of this shortcut, you cannot have a field in your model called
|
||||
``pk`` that is not the primary key of the model. It will always be
|
||||
replaced by the name of the model's primary key in queries.
|
||||
|
||||
Lookups that span relationships
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
|
||||
Reference in New Issue
Block a user