mirror of
https://github.com/django/django.git
synced 2024-12-22 17:16:24 +00:00
Doc'd that Meta.indexes is preferred to Field.db_index.
This commit is contained in:
parent
2c428b37ae
commit
f9fe062de5
@ -351,6 +351,13 @@ looking at your Django code. For example::
|
|||||||
|
|
||||||
If ``True``, a database index will be created for this field.
|
If ``True``, a database index will be created for this field.
|
||||||
|
|
||||||
|
.. admonition:: Use the :attr:`~Options.indexes` option instead.
|
||||||
|
|
||||||
|
Where possible, use the :attr:`Meta.indexes <Options.indexes>` option
|
||||||
|
instead. In nearly all cases, :attr:`~Options.indexes` provides more
|
||||||
|
functionality than ``db_index``. ``db_index`` may be deprecated in the
|
||||||
|
future.
|
||||||
|
|
||||||
``db_tablespace``
|
``db_tablespace``
|
||||||
-----------------
|
-----------------
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user