I upgraded from version 5.x-1.0 to 5.x-1.7.
After I used the update.php-script once, I get the following error-message:

user warning: Duplicate entry '2' for key 1 query: INSERT INTO privatemsg (id, author, recipient, subject, message, timestamp, newmsg, hostname, format) VALUES (2, 6, 8, 'dfm', 'vmxc,', 1176395222, 1, '84.168.244.34', 1) in /home/www/web161/html/includes/database.mysql.inc on line 167.

Also the messages are not send anymore.

Is this a bug or did I do something wrong?

Regards,

Marco

Comments

rszrama’s picture

Yeah, there's a bug in the update function. It's taking away the auto_increment from the privatemsg tables and trying to create a proper entry in the sequence table... but for some reason it fails. Just go into the sequence table and manually up the value for the privatemsg sequence to whatever your max privatemsg id is + 1.

mindless’s picture

rszrama, do you know what the bug is? I can't find anything wrong in the queries to get the initial sequence value.

rszrama’s picture

Honestly, I have no clue. For some reason the max ID in my privatemsg_archive table overrode the max ID in privatemsg even though it was lower. The code seems like it should work, though.

mrgoltra’s picture

subscribing

kkkkkkkkkkkkkkkkkkkkkkk’s picture

Version: 5.x-1.7 » 5.x-1.8
berdir’s picture

Status: Active » Closed (won't fix)

I'm closing old issues since this version isn't supported anymore.