From: Dehua Yang Date: October 17 2012 4:24pm Subject: Re: Possible to copy the key field to another on INSERT? List-Archive: http://lists.mysql.com/mysql/228444 Message-Id: MIME-Version: 1.0 Content-Type: multipart/alternative; boundary=20cf300e4cab86197c04cc43b488 --20cf300e4cab86197c04cc43b488 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hello Shawn Thanks for your tips. We send the " select LAST_INSERT_ID() " by our data middle ware. I'll ask the middle ware team to check it out. On Wed, Oct 17, 2012 at 9:33 PM, Shawn Green wrot= e: > Hello Dehua, > > > On 10/17/2012 3:33 AM, Dehua Yang wrote: > >> select LAST_INSERT_ID() ; Under high concurrency , it would return >> other >> threads value to you. >> >> > Incorrect. The results of LAST_INSERT_ID() are connection-specific. The > activity on other connections will not change or alter the value for the > current connection. Only actions taken by the current connection can > change this value. > > http://dev.mysql.com/doc/**refman/5.5/en/information-** > functions.html#function_last-**insert-id > > > -- > Shawn Green > MySQL Principal Technical Support Engineer > Oracle USA, Inc. - Hardware and Software, Engineered to Work Together. > Office: Blountville, TN > > > > > -- > MySQL General Mailing List > For list archives: http://lists.mysql.com/mysql > To unsubscribe: http://lists.mysql.com/mysql > > --=20 B.rgds / Whitepoplar (=E6=9D=A8=E5=BE=B7=E5=8D=8E=EF=BC=89 --20cf300e4cab86197c04cc43b488--