mirror of
https://github.com/django/django.git
synced 2025-09-16 05:59:33 +00:00
code review fixes (III)
This commit is contained in:
parent
ae301918d3
commit
6a55b66fac
@ -47,11 +47,9 @@ The above ``Person`` model would create a database table like this:
|
|||||||
|
|
||||||
Some technical notes:
|
Some technical notes:
|
||||||
|
|
||||||
* The name of the table, ``myapp_person``, is automatically derived from
|
* By default, the name of the table (``myapp_person``) is automatically derived
|
||||||
some model metadata but can be overridden, normally are automatically
|
from model metadata, combining the name of the app (``myapp``) and the lowercase
|
||||||
generated by combining the name of the app (``myapp``) and the lowercase
|
name of the model (``person``). See :ref:`table-names` for more details.
|
||||||
name of the model (``person``) . See :ref:`table-names` for more
|
|
||||||
details.
|
|
||||||
|
|
||||||
* An ``id`` field is added automatically, but this behavior can be
|
* An ``id`` field is added automatically, but this behavior can be
|
||||||
overridden. See :ref:`automatic-primary-key-fields`.
|
overridden. See :ref:`automatic-primary-key-fields`.
|
||||||
@ -66,7 +64,7 @@ Some technical notes:
|
|||||||
* It's tailored to the database you're using, so database-specific field types
|
* It's tailored to the database you're using, so database-specific field types
|
||||||
such as ``auto_increment`` (MySQL), ``bigint PRIMARY KEY GENERATED BY DEFAULT
|
such as ``auto_increment`` (MySQL), ``bigint PRIMARY KEY GENERATED BY DEFAULT
|
||||||
AS IDENTITY`` (PostgreSQL), or ``integer primary key autoincrement`` (SQLite)
|
AS IDENTITY`` (PostgreSQL), or ``integer primary key autoincrement`` (SQLite)
|
||||||
are handled for you automatically. Same goes for the quoting of field names
|
are handled for you automatically. The same goes for the quoting of field names
|
||||||
-- e.g., using double quotes or single quotes.
|
-- e.g., using double quotes or single quotes.
|
||||||
|
|
||||||
Using models
|
Using models
|
||||||
|
Loading…
x
Reference in New Issue
Block a user