Django CharField vs TextField
Django tip:
Use
models.TextField
for storing long texts inside your models instead ofmodels.CharField
sinceCharField
has a max length of 255 characters whileTextField
can hold more than 255 characters.An example:
from django.db import models class Blog(models.Model): title = models.CharField(max_length=120) content = models.TextField() contributors = models.TextField()