Skip to content

Commit

Permalink
python/django: Fix RST spacing
Browse files Browse the repository at this point in the history
  • Loading branch information
jpmckinney authored Aug 26, 2024
1 parent 3c34cb0 commit 77ddf71
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/python/django.rst
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ In order of importance:

- Reduce the number of SQL queries (avoid `N+1 queries <https://docs.sentry.io/product/issues/issue-details/performance-issues/n-one-queries/>`__):

- Avoid queries inside a loop. For ``SELECT``, perform a single query before the loop (or do the work in batches). For ``INSERT``and ``UPDATE``, use the `bulk_create <https://docs.djangoproject.com/en/4.2/ref/models/querysets/#django.db.models.query.QuerySet.bulk_create>`__ and `bulk_update <https://docs.djangoproject.com/en/4.2/ref/models/querysets/#django.db.models.query.QuerySet.bulk_update>`__ methods after the loop (or do the work in batches).
- Avoid queries inside a loop. For ``SELECT``, perform a single query before the loop (or do the work in batches). For ``INSERT`` and ``UPDATE``, use the `bulk_create <https://docs.djangoproject.com/en/4.2/ref/models/querysets/#django.db.models.query.QuerySet.bulk_create>`__ and `bulk_update <https://docs.djangoproject.com/en/4.2/ref/models/querysets/#django.db.models.query.QuerySet.bulk_update>`__ methods after the loop (or do the work in batches).

.. warning::

Expand Down

0 comments on commit 77ddf71

Please sign in to comment.