Ticket #1562: inspect-setnull.2.diff
File inspect-setnull.2.diff, 615 bytes (added by , 19 years ago) |
---|
-
django/core/management.py
a b def inspectdb(db_name): 727 727 if att_name == 'id' and field_type == 'AutoField(' and extra_params == {'primary_key': True}: 728 728 continue 729 729 730 # Handle "null_ok" flag 731 if row[6]: 732 extra_params["blank"] = True 733 if not field_type in ("TextField","CharField"): 734 extra_params["null"] = True 735 730 736 field_desc = '%s = models.%s' % (att_name, field_type) 731 737 if extra_params: 732 738 if not field_desc.endswith('('):