Skip to content
  • Rahul Malik's avatar
    1ccd472d
    Bug#15851528 DUPLICATE KEY ERROR ON AUTO-INC PK WITH MIXED AUTO_INCREMENT_INCREMENT CLIENTS · 1ccd472d
    Rahul Malik authored
    Problem:
    Clients running different values for auto_increment_increment
    and doing concurrent inserts leads to "Duplicate key error" in one of them.
    
    Analysis:
    When Autoinc_increment value is reduced in a session,
    InnoDB uses last autoinc_increment value
    to recalculate the autoinc value.
    In case, some other session has inserted a value
    with different autoinc_increment, InnoDB recalculate
    autoinc values based on current session previous autoinc_increment
    instead of considering the autoinc_increment used for last insert
    across all session
    
    Fix:
    revert 1d4494d93c2f as it causing the current bug.
    
    Reviewed By:
    Bin <bin.x.su@oracle.com>
    Kevin <kevin.lewis@oracle.com>
    RB#21777
    1ccd472d
    Bug#15851528 DUPLICATE KEY ERROR ON AUTO-INC PK WITH MIXED AUTO_INCREMENT_INCREMENT CLIENTS
    Rahul Malik authored
    Problem:
    Clients running different values for auto_increment_increment
    and doing concurrent inserts leads to "Duplicate key error" in one of them.
    
    Analysis:
    When Autoinc_increment value is reduced in a session,
    InnoDB uses last autoinc_increment value
    to recalculate the autoinc value.
    In case, some other session has inserted a value
    with different autoinc_increment, InnoDB recalculate
    autoinc values based on current session previous autoinc_increment
    instead of considering the autoinc_increment used for last insert
    across all session
    
    Fix:
    revert 1d4494d93c2f as it causing the current bug.
    
    Reviewed By:
    Bin <bin.x.su@oracle.com>
    Kevin <kevin.lewis@oracle.com>
    RB#21777
Loading