  
  You can override the ``FOO_set`` name by setting the
  :attr:`~django.db.models.ForeignKey.related_name` parameter in the
  :class:`~django.db.models.ForeignKey` definition. For example, if the ``Entry``
  model was altered to ``blog = ForeignKey(Blog, related_name='entries')``, the
  above example code would look like this::
  
      >>> b = Blog.objects.get(id=1)
      >>> b.entries.all() # Returns all Entry objects related to Blog.
  
      # b.entries is a Manager that returns QuerySets.
 
</s> remove         entry = models.OneToOneField(Entry)
 </s> add         entry = models.OneToOneField(Entry, on_delete=models.CASCADE) </s> remove     honeycomb = models.ForeignKey(Honeycomb)
 </s> add     honeycomb = models.ForeignKey(Honeycomb, models.CASCADE) </s> remove         company_that_makes_it = models.ForeignKey(Manufacturer)
 </s> add         company_that_makes_it = models.ForeignKey(
            Manufacturer,
            on_delete=models.CASCADE,
        ) </s> remove     poll = models.ForeignKey(Poll, verbose_name="the related poll")
 </s> add     poll = models.ForeignKey(
        Poll,
        on_delete=models.CASCADE,
        verbose_name="the related poll",
    ) </s> remove     x1 = models.ForeignKey(X, related_name='y1')
 </s> add     x1 = models.ForeignKey(X, models.CASCADE, related_name='y1')
model was altered to ``blog = ForeignKey(Blog, on_delete=models.CASCADE,
related_name='entries')``, the above example code would look like this::
  
  You can override the ``FOO_set`` name by setting the
  :attr:`~django.db.models.ForeignKey.related_name` parameter in the
  :class:`~django.db.models.ForeignKey` definition. For example, if the ``Entry``
model was altered to ``blog = ForeignKey(Blog, on_delete=models.CASCADE,
related_name='entries')``, the above example code would look like this::
model was altered to ``blog = ForeignKey(Blog, on_delete=models.CASCADE,
related_name='entries')``, the above example code would look like this::
  
      >>> b = Blog.objects.get(id=1)
      >>> b.entries.all() # Returns all Entry objects related to Blog.
  
      # b.entries is a Manager that returns QuerySets.
keep keep keep keep replace replace keep keep keep keep keep
 Fixed #21127 -- Started deprecation toward requiring on_delete for ForeignKey/OneToOneField 
docs/topics/db/queries.txt