<!DOCTYPE html>
<html>
  <head>
  </head>
  <body>
    <dl style="line-height: 1.5; margin-left: 2em">
      <dt style="clear: both; float: left; font-weight: bold; width: 8em">Author</dt>
      <dd style="margin-left: 8.5em">Kouhei Sutou &lt;kou****@clear*****&gt;</dd>
      <dt style="clear: both; float: left; font-weight: bold; width: 8em">Date</dt>
      <dd style="margin-left: 8.5em">2012-03-20 21:29:09 +0900 (Tue, 20 Mar 2012)</dd>
      <dt style="clear: both; float: left; font-weight: bold; width: 8em">New Revision</dt>
      <dd style="margin-left: 8.5em"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f">4dd2982b632a72e73359cec075960880a19e392f</a></dd>
      <dt style="clear: both; float: left; font-weight: bold; width: 8em">Log</dt>
      <dd style="margin-left: 8.5em"><pre style="border: 1px solid #aaa; font-family: Consolas, Menlo, &quot;Liberation Mono&quot;, Courier, monospace; line-height: 1.2; padding: 0.5em">mariadb55: force enabling cond_push

Optimization for the following SQL requries cond_push:

  SELECT * FROM ...
           WHERE MATCH(...) AGAINST(..) AND
                 int_column = int_value
           ORDER BY ... LIMIT ...;

Should we use
  SET GLOBAL optimizer_switch='engine_condition_pushdown=on';
instead to enable cond_push?

MariaDB 5.5 disables cond_push by default. We can enable it by the
above &quot;SET&quot; command or this change.

MySQL doesn't disable cond_push...

fixes #1315

Reported by Kazuhiko Shiozaki. Thanks!!!</pre></dd>
      <dt style="clear: both; float: left; font-weight: bold; width: 8em">Modified files</dt>
      <dd style="margin-left: 8.5em">
        <ul>
          <li><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#diff-0">ha_mroonga.cc</a></li>
        </ul>
      </dd>
    </dl>

    <div class="diff-section" style="clear: both">
      <table style="border-collapse: collapse; border: 1px solid #aaa">
        <thead>
          <tr class="diff-header" style="border: 1px solid #aaa">
            <td colspan="3">
<pre style="border: 0; font-family: Consolas, Menlo, &quot;Liberation Mono&quot;, Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal"><span class="diff-header" style="background-color: #eaf2f5; color: #999999; display: block; white-space: pre">  Modified: ha_mroonga.cc (+3 -0)</span>
<span class="diff-header-mark" style="background-color: #eaf2f5; color: #999999; display: block; white-space: pre">===================================================================</span>
</pre>
            </td>
          </tr>
        </thead>
        <tbody>
          <tr>
            <th class="diff-line-number" style="border: 1px solid #aaa">
<pre style="border: 0; font-family: Consolas, Menlo, &quot;Liberation Mono&quot;, Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal"><span class="diff-line-number-hunk-header" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0L1973">...</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0L1974">1974</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0L1975">1975</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0L1976">1976</a></span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre">&nbsp;</span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre">&nbsp;</span>
<span class="diff-line-number-nothing" style="display: block; white-space: pre">&nbsp;</span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0L1977">1977</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0L1978">1978</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0L1979">1979</a></span>
</pre>
            </th>
            <th class="diff-line-number" style="border: 1px solid #aaa">
<pre style="border: 0; font-family: Consolas, Menlo, &quot;Liberation Mono&quot;, Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal"><span class="diff-line-number-hunk-header" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0R1973">...</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0R1974">1974</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0R1975">1975</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0R1976">1976</a></span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0R1977">1977</a></span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0R1978">1978</a></span>
<span class="diff-line-number-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0R1979">1979</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0R1980">1980</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0R1981">1981</a></span>
<span class="diff-line-number-not-changed" style="display: block; white-space: pre"><a href="https://github.com/mroonga/mroonga/commit/4dd2982b632a72e73359cec075960880a19e392f#L0R1982">1982</a></span>
</pre>
            </th>
            <td class="diff-content" style="border: 1px solid #aaa">
<pre style="border: 0; font-family: Consolas, Menlo, &quot;Liberation Mono&quot;, Courier, monospace; line-height: 1.2; margin: 0; padding: 0.5em; white-space: normal"><span class="diff-hunk-header" style="background-color: #eaf2f5; color: #999999; display: block; white-space: pre">@@ -1974,6 +1974,9 @@ <span class="diff-context" style="background-color: #ffffaa; color: #000000">ulonglong ha_mroonga::storage_table_flags() const</span></span>
<span class="diff-not-changed" style="display: block; white-space: pre">     HA_CAN_GEOMETRY |</span>
<span class="diff-not-changed" style="display: block; white-space: pre">     HA_CAN_RTREEKEYS;</span>
<span class="diff-not-changed" style="display: block; white-space: pre">     //HA_HAS_RECORDS;</span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+#ifdef HA_MUST_USE_TABLE_CONDITION_PUSHDOWN</span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+  flags |= HA_MUST_USE_TABLE_CONDITION_PUSHDOWN;</span>
<span class="diff-added" style="background-color: #aaffaa; color: #000000; display: block; white-space: pre">+#endif</span>
<span class="diff-not-changed" style="display: block; white-space: pre">   DBUG_RETURN(flags);</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> }</span>
<span class="diff-not-changed" style="display: block; white-space: pre"> </span>
</pre>
            </td>
          </tr>
        </tbody>
      </table>
    </div>
  </body>
</html>