Re: bugs Digest 4 Aug 2004 01:10:15 -0000 Issue 618

Fred <[email protected]> Thu, 05 Aug 2004 03:28:07 -0400
Newsgroups gmane.comp.db.mysql.bugs
Organization HydraNuke.com
Message-ID <1091690886.22999.1.camel@jupiter>
On Tue, 2004-08-03 at 22:52, philo vivero wrote:
> > update foobar set id = id+10000;
> > -- red is 10001, blue is 10002, green is 10003, the next auto_increment
> > entry SHOULD BE 10004
> > 
> > insert into foobar (name) values ("white");
> > -- white's id is 4 instead of 10004
> > 
> > Version:
> > mysql  Ver 12.22 Distrib 4.0.20, for pc-linux (i686)
> 
> Must be an introduced bug. My 4.0.12 doesn't have this problem:

Did you make the table type=InnoDB? It's not clear from your example.

-Fred

> mysql> select * from autoinc ;
> +---+--------------+
> | a | name         |
> +---+--------------+
> | 4 | fred         |
> | 5 | jeff         |
> | 6 | mark         |
> | 7 | lisa         |
> | 8 | mary         |
> | 9 | verchantelle |
> +---+--------------+
> 6 rows in set (0.00 sec)
> 
> mysql> update autoinc set a=a+10000 ;
> Query OK, 6 rows affected (0.00 sec)
> Rows matched: 6  Changed: 6  Warnings: 0
> 
> mysql> insert into autoinc (name) values
> ('genevieve'),('trai-nelle'),('rachellette') ;
> Query OK, 3 rows affected (0.00 sec)
> Records: 3  Duplicates: 0  Warnings: 0
> 
> mysql> select * from autoinc ;
> +-------+--------------+
> | a     | name         |
> +-------+--------------+
> | 10004 | fred         |
> | 10005 | jeff         |
> | 10006 | mark         |
> | 10007 | lisa         |
> | 10008 | mary         |
> | 10009 | verchantelle |
> | 10010 | genevieve    |
> | 10011 | trai-nelle   |
> | 10012 | rachellette  |
> +-------+--------------+
> 9 rows in set (0.00 sec)
> 
> mysql> select version() ;
> +------------+
> | version()  |
> +------------+
> | 4.0.12-log |
> +------------+
> 
> -- 
> pv
-- 
Fred Mitchell, HydraNuke.com
E-Commerce and Hosting Solutions 
Whatever you want, we'll make it happen
(603)557-5986
signature.asc (application/pgp-signature, 189 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)

iD8DBQBBEeGFVZ97vCsahg4RAq/uAJ9/CTEZovQ/rm5y57QGdHjcy6Ts5ACdFljh
eaho029roEgXta1mhA30xNQ=
=hqtl
-----END PGP SIGNATURE-----