diff --git a/docs/topics/db/queries.txt b/docs/topics/db/queries.txt index 34a8b7943aa..5e353b2ec3e 100644 --- a/docs/topics/db/queries.txt +++ b/docs/topics/db/queries.txt @@ -946,15 +946,13 @@ in the :ref:`related objects reference `. To assign the members of a related set in one fell swoop, just assign to it from any iterable object. The iterable can contain object instances, or just -a list of primary key values. For Example:: - -Example:: +a list of primary key values. For example:: b = Blog.objects.get(id=1) b.entry_set = [e1, e2] In this example, ``e1`` and ``e2`` can be full Entry instances, or integer -values representing primary keys. +primary key values. If the ``clear()`` method is available, any pre-existing objects will be removed from the ``entry_set`` before all objects in the iterable (in this