• Timothy Smith's avatar
    Apply InnoDB snapshot innodb-5.1-ss2637, part 2. Fixes · ea912a97
    Timothy Smith authored
    Bug #38839: auto increment does not work properly with InnoDB after update
    
    
    Detailed revision comments:
    
    r2609 | sunny | 2008-08-24 01:19:05 +0300 (Sun, 24 Aug 2008) | 12 lines
    branches/5.1: Fix for MySQL Bug#38839. Reset the statement level last
    value field in prebuilt. This field tracks the last value in an autoincrement
    interval. We use this value to check whether we need to update a table's
    AUTOINC counter, if the value written to a table is less than this value
    then we avoid updating the table's AUTOINC value in order to reduce
    mutex contention. If it's not reset (e.g., after a DELETE statement) then
    there is the possibility of missing updates to the table's AUTOINC counter
    resulting in a subsequent duplicate row error message under certain 
    conditions (see the test case for details).
    
    Bug #38839 - auto increment does not work properly with InnoDB after update
    ea912a97
innodb-autoinc.result 5.09 KB