Re: Table Names and Foreign Keys

2009-12-23 Thread V64
Peter I (think) I am running 1.1.1 on Python 2.4 Yes, the SQL printed out by 'manage.py sql app' looks, as you say, correct. I get the same SQL on my system. It would appear that the 'ALTER TABLE ...' changes the table name to be in lower case! On Dec 23, 5:53 pm, Peter Rowell wrote: > What r

Re: Table Names and Foreign Keys

2009-12-23 Thread Peter Rowell
What rev are you running? I just tried this on Ubuntu 9.04 with Django 1.1.1 and got the following SQL generated. It looks right to me. ./manage.py sql test BEGIN; CREATE TABLE `Register` ( `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY, `name` varchar(48) NOT NULL UNIQUE, `title` va

Table Names and Foreign Keys

2009-12-23 Thread V64
class Register(models.Model): name = models.CharField(unique=True, max_length=48, db_column='name', blank=True) title = models.CharField(max_length=48, blank=True) firstname = models.CharField(max_length=48, blank=True) class Meta: db_table = u'Register' class Charity(mode