Skip to content

Tag Archives: Django-models

IntegerField is a integer number represented in Python by a int instance. This field is generally used to store integer numbers in the database. The… Read More
GenericIPAddressField is a field which stores an IPv4 or IPv6 address, in string format (e.g. 192.0.2.30 or 2a02:42fe::4). The default form widget for this field… Read More
ImageField is a FileField with uploads restricted to image formats only. Before uploading files, one needs to specify a lot of settings so that file… Read More
FilePathField is a CharField whose choices are limited to the filenames in a certain directory on the filesystem. FilePathField instances are created in your database… Read More
BinaryField is a special field to store raw binary data. It can be assigned bytes, bytearray, or memoryview. By default, BinaryField sets editable to False,… Read More
BigIntegerField is a 64-bit integer, much like an IntegerField except that it is guaranteed to fit numbers from -9223372036854775808 to 9223372036854775807. The default form widget… Read More
FloatField is a floating-point number represented in Python by a float instance. This field is generally used to store huge floating point numbers in the… Read More
FileField is a file-upload field. Before uploading files, one needs to specify a lot of settings so that file is securely saved and can be… Read More
BooleanField is a true/false field. It is like a bool field in C/C+++. The default form widget for this field is CheckboxInput, or NullBooleanSelect if… Read More
CharField is a string field, for small- to large-sized strings. It is like a string field in C/C+++. CharField is generally used for storing small… Read More
DateField is a field that stores date, represented in Python by a datetime.date instance. As the name suggests, this field is used to store an… Read More
DateTimeField is a date and time field which stores date, represented in Python by a datetime.datetime instance. As the name suggests, this field is used… Read More
DecimalField is a field which stores a fixed-precision decimal number, represented in Python by a Decimal instance. It validates the input using DecimalValidator. Syntax field_name… Read More
DurationField is a field for storing periods of time – modeled in Python by timedelta. When used on PostgreSQL, the data type used is an… Read More
EmailField is a CharField that checks the value for a valid email address using EmailValidator. EmailValidator validates a email through predefined regex which checks ‘@’… Read More