Bug with Innodb and REPLACE in MySQL-4.1
am 17.11.2002 02:15:39 von Jocelyn Fournier
Hi,
How-to-repeat :
CREATE TABLE `vttattitude_new_msg` (
`id` int(11) unsigned NOT NULL auto_increment,
`id_forum` tinyint(3) unsigned NOT NULL default '0',
`id_user` smallint(5) unsigned NOT NULL default '0',
`last_visit` int(11) unsigned NOT NULL default '0',
PRIMARY KEY (`id`),
UNIQUE KEY `id_forum` (`id_forum`,`id_user`)
) TYPE=InnoDB PACK_KEYS=1;
REPLACE INTO vttattitude_new_msg(id_forum,id_user,last_visit)
VALUES('1','18','1037494810');
Query OK, 1 row affected (0.00 sec)
REPLACE INTO vttattitude_new_msg(id_forum,id_user,last_visit)
VALUES('1','18','1037494810');
Query OK, 2 rows affected (0.00 sec)
REPLACE INTO vttattitude_new_msg(id_forum,id_user,last_visit)
VALUES('1','18','1037494810');
ERROR 1062: Duplicate entry '2' for key 1
This works just fine with a MyISAM table.
Regards,
Jocelyn
------------------------------------------------------------ ---------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail bugs-thread13017@lists.mysql.com
To unsubscribe, e-mail
Re: Bug with Innodb and REPLACE in MySQL-4.1
am 17.11.2002 02:23:34 von Jocelyn Fournier
humm it seems finally you've already fixed this bug in the 4.0 tree, sorry
:)
(Fix bug intoduced in 4.0.4 in REPLACE and AUTO_INCREMENT: if replace did an
update, then auto-inc counter was left 1 too low)
I'll wait for the merge ;)
Regards,
Jocelyn
----- Original Message -----
From: "Jocelyn Fournier"
To: ; "Heikki Tuuri"
Sent: Sunday, November 17, 2002 1:15 AM
Subject: Bug with Innodb and REPLACE in MySQL-4.1
> Hi,
>
> How-to-repeat :
>
>
> Regards,
> Jocelyn
>
------------------------------------------------------------ ---------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail bugs-thread13018@lists.mysql.com
To unsubscribe, e-mail
Re: Bug with Innodb and REPLACE in MySQL-4.1
am 18.11.2002 17:17:37 von Sinisa Milivojevic
Jocelyn Fournier writes:
> humm it seems finally you've already fixed this bug in the 4.0 tree, sorry
> :)
> (Fix bug intoduced in 4.0.4 in REPLACE and AUTO_INCREMENT: if replace did an
> update, then auto-inc counter was left 1 too low)
> I'll wait for the merge ;)
>
> Regards,
> Jocelyn
>
Yes, it is fixed.
No need to apologize ... ;o)
--
Regards,
__ ___ ___ ____ __
/ |/ /_ __/ __/ __ \/ / Mr. Sinisa Milivojevic
/ /|_/ / // /\ \/ /_/ / /__ MySQL AB, Fulltime Developer
/_/ /_/\_, /___/\___\_\___/ Larnaca, Cyprus
<___/ www.mysql.com
------------------------------------------------------------ ---------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail bugs-thread13022@lists.mysql.com
To unsubscribe, e-mail