hi all, yet another question here:
I enabled the 'django.contrib.comments' in the settings.py then, I ran: $ python manage.py syncdb I got the following error: ----------------------------------------- Creating table comments_comment Creating table comments_freecomment Creating table comments_karmascore Creating table comments_moderatordeletion Creating table comments_userflag Traceback (most recent call last): File "manage.py", line 11, in ? execute_manager(settings) File "/mnt/data/workspace/svn-django-m-r/magic-removal/django/core/management.py", line 1226, in execute_manager execute_from_command_line(action_mapping) File "/mnt/data/workspace/svn-django-m-r/magic-removal/django/core/management.py", line 1152, in execute_from_command_line action_mapping[action]() File "/mnt/data/workspace/svn-django-m-r/magic-removal/django/core/management.py", line 472, in syncdb app=app, created_models=created_models) File "/mnt/data/workspace/svn-django-m-r/magic-removal/django/dispatch/dispatcher.py", line 347, in send sender=sender, File "/mnt/data/workspace/svn-django-m-r/magic-removal/django/dispatch/robustapply.py", line 47, in robustApply return receiver(*arguments, **named) File "/mnt/data/workspace/svn-django-m-r/magic-removal/django/contrib/auth/management.py", line 34, in create_permissions p.save() File "/mnt/data/workspace/svn-django-m-r/magic-removal/django/db/models/base.py", line 186, in save ','.join(placeholders)), db_values) File "/mnt/data/workspace/svn-django-m-r/magic-removal/django/db/backends/util.py", line 12, in execute return self.cursor.execute(sql, params) File "/mnt/data/workspace/svn-django-m-r/magic-removal/django/db/backends/sqlite3/base.py", line 69, in execute return Database.Cursor.execute(self, query, params) pysqlite2.dbapi2.IntegrityError: columns content_type_id, codename are not unique ---------------------------------------- I dug into the tables I've already have, and the schema for auth_permission is: CREATE TABLE "auth_permission" ( "id" integer NOT NULL PRIMARY KEY, "name" varchar(50) NOT NULL, "content_type_id" integer NOT NULL, "codename" varchar(100) NOT NULL, UNIQUE ("content_type_id", "codename") ); it seems that the comments module is trying to write something to the auth_permission table while running syncdb? however, if I ran: $ python manage.py sqlall comments > comments.sql and then read the comments.sql in the sqlite3's shell, everything works fine and there is no sql writing things into auth_permission table in the comments.sql file. so the syncdb does more things than the sqlall? If I use the sqlall output sql to create tables for the comments module, will there be any problem I'm going to encounter in the future? TIA :) - Eric --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users -~----------~----~----~----~------~----~------~--~---