• unknown's avatar
    Bug#30384: Having SQL_BUFFER_RESULT option in the CREATE .. KEY(..) .. SELECT · 4addb6b7
    unknown authored
    led to creating corrupted index.
    
    Corrected fix. The new method called prepare2 is added to the select_create
    class. As all preparations are done by the select_create::prepare function
    it doesn't do anything. Slightly changed algorithm of calling the 
    start_bulk_insert function. Now it's called from the select_insert::prepare2
    function when the SQL_BUFFER_RESULT flags is set.
    The is_bulk_insert_mode flag is removed as it is not needed anymore.
    
    
    sql/sql_class.h:
      Bug#30384: Having SQL_BUFFER_RESULT option in the CREATE .. KEY(..) .. SELECT
      led to creating corrupted index.
      Corrected fix. The new method called prepare2 is added to the select_create
      class. As all preparetions are done by the select_create::prepare function
      it doesn't do anything.
      The is_bulk_insert_mode flag is removed as it is not needed anymore.
    sql/sql_insert.cc:
      Bug#30384: Having SQL_BUFFER_RESULT option in the CREATE .. KEY(..) .. SELECT
      led to creating corrupted index. Slightly changed algorithm of calling the
      start_bulk_insert function. Now it's called from the select_insert::prepare2
      function when the SQL_BUFFER_RESULT flags is set.
      Corrected fix. The is_bulk_insert_mode flag is removed as it is not needed
      anymore.
    4addb6b7
sql_insert.cc 107 KB