db.models.Field.rel_db_type()
  • References/Python/Django/API/Models/Model field reference

rel_db_type(connection) [source] New in Django

2025-01-10 15:47:30
db.models.Field.unique_for_year
  • References/Python/Django/API/Models/Model field reference

Field.unique_for_year Like unique_for_date and unique_for_month.

2025-01-10 15:47:30
db.models.Field.blank
  • References/Python/Django/API/Models/Model field reference

Field.blank If True, the field is allowed to be blank. Default is False. Note

2025-01-10 15:47:30
db.models.Field.pre_save()
  • References/Python/Django/API/Models/Model field reference

pre_save(model_instance, add) [source] Method called prior to get_db_prep_save()

2025-01-10 15:47:30
db.models.fields.files.FieldFile.close()
  • References/Python/Django/API/Models/Model field reference

FieldFile.close() [source] Behaves like the standard Python file.close() method

2025-01-10 15:47:30
db.models.Field.unique_for_date
  • References/Python/Django/API/Models/Model field reference

Field.unique_for_date Set this to the name of a DateField or DateTimeField to require that this field

2025-01-10 15:47:30
db.models.ForeignKey.limit_choices_to
  • References/Python/Django/API/Models/Model field reference

ForeignKey.limit_choices_to Sets a limit to the available choices for this field when this field is rendered using a ModelForm

2025-01-10 15:47:30
db.models.GenericIPAddressField.unpack_ipv4
  • References/Python/Django/API/Models/Model field reference

GenericIPAddressField.unpack_ipv4 Unpacks IPv4 mapped addresses like ::ffff:192.0.2.1. If this option is enabled

2025-01-10 15:47:30
db.models.ManyToManyField.swappable
  • References/Python/Django/API/Models/Model field reference

ManyToManyField.swappable Controls the migration framework’s reaction if this ManyToManyField is pointing at a

2025-01-10 15:47:30
db.models.ForeignKey.db_constraint
  • References/Python/Django/API/Models/Model field reference

ForeignKey.db_constraint Controls whether or not a constraint should be created in the database for this foreign key. The default

2025-01-10 15:47:30