Im trying to use the MySite module on my Drupal install but It's giving me the following error:

user warning: Duplicate entry '0' for key 1 query: INSERT INTO dr_mysite (uid, created, status, title) VALUES (0, 1218632077, 1, 'My Homepage') in /var/www/vhosts/mywebsite.com/httpdocs/includes/database.mysql.inc on line 172.

I've uninstalled and reinstalled the module and still get the warning.
Does anyone know what's causing this and how it can be fixed?

Thanks for any info

Drupal 5.9
PHP 5.2.0-8+etch11
MySQL 5.0.32

Comments

djpumpkin’s picture

This problem was documented in another post: 'user warning: Duplicate entry '0' for key 1 query: INSERT INTO mysite'
http://drupal.org/node/270400#comment-962818

It seems that under some circumstances User UID 0 is not created when Drupal is installed - or somehow it gets deleted.
UID 0 represents anonymous users and if it isn't present causes some modules (MySite) for instance to complain.