How to use NullBooleanFieldin models Djangowith SQLlite3, I want to keep the nulldefault value for the field nullBoolean, how to do it?
I migrated db from BooleanFieldto NullBooleanField, but still saves False as the default value.
Use in code:
LOCATOR_YES_NO_CHOICES = ((None,''), (True,'Yes'), (False, 'No'))
employed = models.NullBooleanField(choices=LOCATOR_YES_NO_CHOICES,
max_length=3,
blank=True, null=True, default="",)
Any example would be helpful.
source
share