• unknown's avatar
    Bug#23170: LAST_INSERT_ID isn't reset to 0 in INSERT .. SELECT when no rows were · 27481649
    unknown authored
    inserted.
    
    The select_insert::send_eof() function now resets LAST_INSERT_ID variable if
    no rows were inserted.
    
    
    mysql-test/t/insert_select.test:
      Added a test case for bug#23170: LAST_INSERT_ID isn't reset to 0 in INSERT .. SELECT when no rows were inserted.
    mysql-test/r/insert_select.result:
      Added a test case for bug#23170: LAST_INSERT_ID isn't reset to 0 in INSERT .. SELECT when no rows were inserted.
    sql/sql_insert.cc:
      Bug#23170: LAST_INSERT_ID isn't reset to 0 in INSERT .. SELECT when no rows were
      inserted.The select_insert::send_eof() function now resets LAST_INSERT_ID variable if
      no rows were inserted.
    27481649
sql_insert.cc 92 KB