If I create a model in my app with foreign key to the User model, the
SQL for creating the table doesn't add a 'REFERENCES' clause:
Model
-----
class Test(models.Model):
user = models.ForeignKey(User, null=True)
Shell
-----
django-admin.py sqlall myapp --settings='myproj.settings'
BEGIN;
CREATE TABLE "myapp_test" (
"id" serial NOT NULL PRIMARY KEY,
"user_id" integer NULL
);
COMMIT
It works fine for intra-app relations, just not cross-app ones.
Is this a known issue? Is it by design for some reason?
Thanks,
Luke
--
"Where a person wishes to attract, they should always be ignorant."
(Jane Austen)
Luke Plant || L.Plant.98 (at) cantab.net || http://lukeplant.me.uk/
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-developers
-~----------~----~----~----~------~----~------~--~---