summaryrefslogtreecommitdiff
path: root/docs/topics/db/sql.txt
diff options
context:
space:
mode:
authorSimon Charette <charette.s@gmail.com>2019-11-15 16:20:07 -0500
committerMariusz Felisiak <felisiak.mariusz@gmail.com>2019-11-18 14:06:51 +0100
commit11e327a3ff84e16ceace13ea6ec408a93ca9e72c (patch)
tree438e482ac75e6ae404920493a628eb00e7519e59 /docs/topics/db/sql.txt
parentcbe4d6203ff2d702b63dae52adbe7a50830a5cbe (diff)
downloaddjango-11e327a3ff84e16ceace13ea6ec408a93ca9e72c.tar.gz
Fixed #30988 -- Deprecated the InvalidQuery exception.
It was barely documented without pointers at its defining location and was abused to prevent misuse of the QuerySet field deferring feature.
Diffstat (limited to 'docs/topics/db/sql.txt')
-rw-r--r--docs/topics/db/sql.txt5
1 files changed, 3 insertions, 2 deletions
diff --git a/docs/topics/db/sql.txt b/docs/topics/db/sql.txt
index f0af7a4b44..355c7366ca 100644
--- a/docs/topics/db/sql.txt
+++ b/docs/topics/db/sql.txt
@@ -170,8 +170,9 @@ last names were both retrieved on demand when they were printed.
There is only one field that you can't leave out - the primary key
field. Django uses the primary key to identify model instances, so it
-must always be included in a raw query. An ``InvalidQuery`` exception
-will be raised if you forget to include the primary key.
+must always be included in a raw query. A
+:class:`~django.core.exceptions.FieldDoesNotExist` exception will be raised if
+you forget to include the primary key.
Adding annotations
------------------