1. 19 Jan, 2005 1 commit
    • unknown's avatar
      BUG#6034 - Error code 124: Wrong medium type. · ab7f56e3
      unknown authored
      Version for 5.0. Committed for merge.
      If the result table is one of the select tables in INSERT SELECT,
      we must not disable the result tables indexes before selecting.
      Now the preparation is split into two prepare methods.
      The first detects the situation and defers some preparations
      until the second phase.
      
      
      mysql-test/r/insert_select.result:
        BUG#6034 - Error code 124:  Wrong medium type.
        The test results.
      mysql-test/t/insert_select.test:
        BUG#6034 - Error code 124:  Wrong medium type.
        The test case.
      sql/sql_class.h:
        BUG#6034 - Error code 124:  Wrong medium type.
        Added a new method for deferred preparation actions.
      sql/sql_insert.cc:
        BUG#6034 - Error code 124:  Wrong medium type.
        If the insert table is one of the select tables, a part 
        of the result table preparations like disabling indexes
        has to be done after the select phase.
        This is now done in the new method select_insert::prepare2().
      sql/sql_select.cc:
        BUG#6034 - Error code 124:  Wrong medium type.
        The result table preparation is now split into prepare() and
        prepare2(). Disabling indexes and other preparation stuff
        is deferred until after the selection phase.
      ab7f56e3
  2. 18 Jan, 2005 39 commits