diff options
| author | Tim Graham <timograham@gmail.com> | 2015-08-03 17:05:18 -0400 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2015-08-05 08:15:44 -0400 |
| commit | ce0f2a4a4f192caf46cc9edd843c87862a668161 (patch) | |
| tree | 394dba8551421384a16928daec08c9682c98cda2 /docs/topics | |
| parent | 6f6043fd26a83bd0625ce34e1f64a1663fec26db (diff) | |
[1.8.x] Fixed #25213 -- Discouraged use of QuerySet.extra()
Thanks Anssi Kääriäinen for the draft text and Simon Charette
for review.
Backport of e8cd65f8297928d3fa7ad3d338953a4423028713 from master
Diffstat (limited to 'docs/topics')
| -rw-r--r-- | docs/topics/db/optimization.txt | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/docs/topics/db/optimization.txt b/docs/topics/db/optimization.txt index 8847663b1b..52238bd714 100644 --- a/docs/topics/db/optimization.txt +++ b/docs/topics/db/optimization.txt @@ -130,12 +130,12 @@ For instance: If these aren't enough to generate the SQL you need: -Use ``QuerySet.extra()`` ------------------------- +Use ``RawSQL`` +-------------- -A less portable but more powerful method is -:meth:`~django.db.models.query.QuerySet.extra()`, which allows some SQL to be -explicitly added to the query. If that still isn't powerful enough: +A less portable but more powerful method is the +:class:`~django.db.models.expressions.RawSQL` expression, which allows some SQL +to be explicitly added to the query. If that still isn't powerful enough: Use raw SQL ----------- |
