<html>
<head>
<title>Test Results</title>
<style>
td.winner { background-color: lightgreen; }
td.loser { background-color: lightyellow; }
td.mismatch { background-color: lightred; }
th { text-align: left; }
</style>
</head>
<body>
<h1>Test Results</h1>
<h2>Summary</h2>
<table border="1">
<tr>
<th>Test</th>
<th>Real</th>
<th>Distributed</th>
<th>Real Distributed</th>
<th>Count</th>
</tr>
<tr>
<td>
<a href="#1 str">1 str</a>
</td>
<td class="winner">
~3.9877474
</td>
<td class="loser">
~11.3112746
</td>
<td></td>
<td class="">
8223
</td>
</tr>
<tr>
<td>
<a href="#1 str w/index">1 str w/index</a>
</td>
<td class="winner">
~0.315735
</td>
<td class="loser">
~2.9904568
</td>
<td></td>
<td class="">
4254
</td>
</tr>
<tr>
<td>
<a href="#1 str bzlike">1 str bzlike</a>
</td>
<td class="loser">
~4.0579302
</td>
<td class="loser">
~17.093645
</td>
<td class="winner">
~1.4311704
</td>
<td class="">
8223
</td>
</tr>
<tr>
<td>
<a href="#1 str bzlike w/index">1 str bzlike w/index</a>
</td>
<td class="winner">
~0.3117504
</td>
<td class="loser">
~3.337467
</td>
<td class="loser">
~0.458596
</td>
<td class="">
4254
</td>
</tr>
<tr>
<td>
<a href="#2 str">2 str</a>
</td>
<td class="winner">
~3.9378638
</td>
<td class="loser">
~5.2932316
</td>
<td></td>
<td class="">
223
</td>
</tr>
<tr>
<td>
<a href="#2 str w/index">2 str w/index</a>
</td>
<td class="winner">
~0.4192676
</td>
<td class="loser">
~3.273968
</td>
<td></td>
<td class="">
64
</td>
</tr>
<tr>
<td>
<a href="#3 str">3 str</a>
</td>
<td class="winner">
~3.9261856
</td>
<td class="loser">
~5.1553084
</td>
<td></td>
<td class="">
4
</td>
</tr>
<tr>
<td>
<a href="#3 str w/index">3 str w/index</a>
</td>
<td class="winner">
~0.407631
</td>
<td class="loser">
~3.3689256
</td>
<td></td>
<td class="">
3
</td>
</tr>
<tr>
<td>
<a href="#10 str">10 str</a>
</td>
<td class="winner">
~4.2357802
</td>
<td class="loser">
~5.202874
</td>
<td></td>
<td class="">
0
</td>
</tr>
<tr>
<td>
<a href="#10 str w/index">10 str w/index</a>
</td>
<td class="winner">
~0.4266194
</td>
<td class="loser">
~3.3956718
</td>
<td></td>
<td class="">
0
</td>
</tr>
<tr>
<td>
<a href="#1 int bzlike">1 int bzlike</a>
</td>
<td class="winner">
~3.5273198
</td>
<td class="loser">
~5.2007874
</td>
<td></td>
<td class="">
149353
</td>
</tr>
<tr>
<td>
<a href="#1 str, 1 int">1 str, 1 int</a>
</td>
<td class="winner">
~4.0352372
</td>
<td class="loser">
~12.3294172
</td>
<td></td>
<td class="">
4102
</td>
</tr>
<tr>
<td>
<a href="#1 str, 1 int w/index">1 str, 1 int w/index</a>
</td>
<td class="winner">
~0.3228126
</td>
<td class="loser">
~3.3190154
</td>
<td></td>
<td class="">
2126
</td>
</tr>
<tr>
<td>
<a href="#2 str, 2 int">2 str, 2 int</a>
</td>
<td class="winner">
~4.043576
</td>
<td class="loser">
~10.8127814
</td>
<td></td>
<td class="">
58
</td>
</tr>
<tr>
<td>
<a href="#2 str, 2 int w/index">2 str, 2 int w/index</a>
</td>
<td class="winner">
~0.402287
</td>
<td class="loser">
~3.5873808
</td>
<td></td>
<td class="">
17
</td>
</tr>
<tr>
<td>
<a href="#simple b.m.o query">simple b.m.o query</a>
</td>
<td class="loser">
~1.8915858
</td>
<td class="loser">
~0.4886198
</td>
<td class="winner">
~0.0966158
</td>
<td class="">
27
</td>
</tr>
<tr>
<td>
<a href="#simple b.m.o query w/index">simple b.m.o query w/index</a>
</td>
<td class="winner">
~0.008117
</td>
<td class="loser">
~3.6754566
</td>
<td class="loser">
~0.0099264
</td>
<td class="">
27
</td>
</tr>
</table>
<h2><a name="1 str">1 str</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE INSTR(cf_aa, 'meta')</p>
<p>Times: 3.988352, 3.982917, 4.05604, 4.00741, 3.946212, 3.946158</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>ALL</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td>300000</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str WHERE field_id = 0 AND INSTR(value, 'meta')</p>
<p>Times: 9.557277, 12.142409, 8.835479, 20.878078, 8.605007, 6.0954</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>distcol_str</td>
<td>ref</td>
<td>field_id</td>
<td>field_id</td>
<td>4</td>
<td>const</td>
<td>253848</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="1 str w/index">1 str w/index</a></h2>
<p>like the standard one-string query, but it searches with 'MATCH... AGAINST', which uses a fulltext index when possible</p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE MATCH(cf_aa) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 0.345353, 0.31228, 0.318064, 0.315559, 0.311634, 0.321138</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>fulltext</td>
<td>cf_aa</td>
<td>cf_aa</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str WHERE field_id = 0 AND MATCH(value) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 3.094618, 2.983644, 3.007893, 3.006676, 2.985868, 2.968203</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>distcol_str</td>
<td>fulltext</td>
<td>field_id,value</td>
<td>value</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="1 str bzlike">1 str bzlike</a></h2>
<p>like the one-string query, but it joins tables in the distributed and real distributed queries just like Bugzilla would</p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE INSTR(cf_aa, 'meta')</p>
<p>Times: 4.069655, 4.007689, 4.184799, 4.105477, 4.074804, 3.916882</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>ALL</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td>300000</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM realcol JOIN distcol_str on realcol.bug_id = distcol_str.bug_id WHERE field_id = 0 AND INSTR(value, 'meta')</p>
<p>Times: 48.293447, 15.735562, 19.767863, 20.582636, 15.265914, 14.11625</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>index</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>4</td>
<td></td>
<td>300000</td>
<td>Using index</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>distcol_str</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.realcol.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h3>Real Distributed</h3>
<p>Query: SELECT COUNT(*) FROM realcol JOIN cf_aa ON realcol.bug_id = cf_aa.bug_id WHERE INSTR(cf_aa.cf_aa, 'meta')</p>
<p>Times: 1.730078, 1.455176, 1.43349, 1.434032, 1.426283, 1.406871</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>cf_aa</td>
<td>ALL</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td>300000</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>eq_ref</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>4</td>
<td>bugs_bmo.cf_aa.bug_id</td>
<td>1</td>
<td>Using index</td>
</tr>
</table>
<h2><a name="1 str bzlike w/index">1 str bzlike w/index</a></h2>
<p>like the one-string query with index, but it joins tables in the distributed and real distributed queries just like Bugzilla would</p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE MATCH(cf_aa) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 0.330958, 0.310043, 0.317101, 0.310285, 0.30997, 0.311353</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>fulltext</td>
<td>cf_aa</td>
<td>cf_aa</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM realcol JOIN distcol_str ON realcol.bug_id = distcol_str.bug_id WHERE field_id = 0 AND MATCH(value) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 10.136337, 3.759189, 3.185504, 3.117585, 3.384042, 3.241015</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>distcol_str</td>
<td>fulltext</td>
<td>PRIMARY,field_id,value</td>
<td>value</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>eq_ref</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>4</td>
<td>bugs_bmo.distcol_str.bug_id</td>
<td>1</td>
<td>Using index</td>
</tr>
</table>
<h3>Real Distributed</h3>
<p>Query: SELECT COUNT(*) FROM realcol JOIN cf_aa ON realcol.bug_id = cf_aa.bug_id WHERE MATCH(cf_aa.cf_aa) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 0.461428, 0.456628, 0.45969, 0.459145, 0.460251, 0.457266</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>cf_aa</td>
<td>fulltext</td>
<td>cf_aa</td>
<td>cf_aa</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>eq_ref</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>4</td>
<td>bugs_bmo.cf_aa.bug_id</td>
<td>1</td>
<td>Using index</td>
</tr>
</table>
<h2><a name="2 str">2 str</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE INSTR(cf_aa, 'meta') AND INSTR(cf_ab, 'meta')</p>
<p>Times: 4.051113, 3.998301, 3.884055, 3.908934, 3.96773, 3.930299</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>ALL</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td>300000</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str d1, distcol_str d2 WHERE d1.bug_id = d2.bug_id AND d1.field_id =0 AND d2.field_id = 1 AND INSTR(d1.value, 'meta') AND INSTR(d2.value, 'meta')</p>
<p>Times: 6.303668, 5.786735, 5.255986, 5.173097, 5.126589, 5.123751</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>ref</td>
<td>PRIMARY,field_id</td>
<td>field_id</td>
<td>4</td>
<td>const</td>
<td>253847</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d1</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d2.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="2 str w/index">2 str w/index</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE MATCH(cf_aa) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ab) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 0.412194, 0.422657, 0.418649, 0.420209, 0.419387, 0.415436</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>fulltext</td>
<td>cf_aa,cf_ab</td>
<td>cf_aa</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str d1, distcol_str d2 WHERE d1.bug_id = d2.bug_id AND d1.field_id =0 AND d2.field_id = 1 AND MATCH(d1.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d2.value) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 3.563141, 3.329249, 3.272768, 3.277731, 3.26358, 3.226512</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d1</td>
<td>fulltext</td>
<td>PRIMARY,field_id,value</td>
<td>value</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d1.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="3 str">3 str</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE INSTR(cf_aa, 'meta') AND INSTR(cf_ab, 'meta') AND INSTR(cf_ac, 'meta')</p>
<p>Times: 3.833516, 3.89157, 3.970004, 4.000053, 3.890243, 3.879058</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>ALL</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td>300000</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str d1, distcol_str d2, distcol_str d3 WHERE d1.bug_id = d2.bug_id AND d2.bug_id = d3.bug_id AND d1.field_id = 0 and d2.field_id = 1 AND d3.field_id = 2 and INSTR(d1.value, 'meta') AND INSTR(d2.value, 'meta') AND INSTR(d3.value, 'meta')</p>
<p>Times: 5.341255, 5.136202, 5.150254, 5.182436, 5.167192, 5.140458</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d1</td>
<td>ref</td>
<td>PRIMARY,field_id</td>
<td>field_id</td>
<td>4</td>
<td>const</td>
<td>253848</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d1.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d3</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d2.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="3 str w/index">3 str w/index</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE MATCH(cf_aa) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ab) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ac) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 0.405497, 0.407601, 0.405479, 0.408969, 0.411977, 0.404129</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>fulltext</td>
<td>cf_aa,cf_ab,cf_ac</td>
<td>cf_aa</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str d1, distcol_str d2, distcol_str d3 WHERE d1.bug_id = d2.bug_id AND d2.bug_id = d3.bug_id AND d1.field_id = 0 and d2.field_id = 1 AND d3.field_id = 2 and MATCH(d1.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d2.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d3.value) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 3.495032, 3.531371, 3.334359, 3.286391, 3.319075, 3.373432</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d1</td>
<td>fulltext</td>
<td>PRIMARY,field_id,value</td>
<td>value</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d1.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d3</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d2.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="10 str">10 str</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE INSTR(cf_aa, 'meta') AND INSTR(cf_ab, 'meta') AND INSTR(cf_ac, 'meta') AND INSTR(cf_ad, 'meta') AND INSTR(cf_ae, 'meta') AND INSTR(cf_af, 'meta') AND INSTR(cf_ag, 'meta') AND INSTR(cf_ah, 'meta') AND INSTR(cf_ai, 'meta') AND INSTR(cf_aj, 'meta')</p>
<p>Times: 4.243142, 4.251353, 4.254027, 4.270421, 4.214122, 4.188978</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>ALL</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td>300000</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str d1, distcol_str d2, distcol_str d3, distcol_str d4, distcol_str d5, distcol_str d6, distcol_str d7, distcol_str d8, distcol_str d9, distcol_str d10 WHERE d1.bug_id = d2.bug_id AND d2.bug_id = d3.bug_id AND d3.bug_id = d4.bug_id AND d4.bug_id = d5.bug_id AND d5.bug_id = d6.bug_id AND d6.bug_id = d7.bug_id AND d7.bug_id = d8.bug_id AND d8.bug_id = d9.bug_id AND d9.bug_id = d10.bug_id AND d1.field_id = 0 AND d2.field_id = 1 AND d3.field_id = 2 AND d4.field_id = 3 AND d5.field_id = 4 AND d6.field_id = 5 AND d7.field_id = 6 AND d8.field_id = 7 AND d9.field_id = 8 AND d10.field_id = 9 AND INSTR(d1.value, 'meta') AND INSTR(d2.value, 'meta') AND INSTR(d3.value, 'meta') AND INSTR(d4.value, 'meta') AND INSTR(d5.value, 'meta') AND INSTR(d6.value, 'meta') AND INSTR(d7.value, 'meta') AND INSTR(d8.value, 'meta') AND INSTR(d9.value, 'meta') AND INSTR(d10.value, 'meta')</p>
<p>Times: 5.189792, 5.248865, 5.215309, 5.165637, 5.162155, 5.222404</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d1</td>
<td>ref</td>
<td>PRIMARY,field_id</td>
<td>field_id</td>
<td>4</td>
<td>const</td>
<td>253848</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d1.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d3</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d2.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d4</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d3.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d5</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d4.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d6</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d5.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d7</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d6.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d8</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d7.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d9</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d8.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d10</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d9.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="10 str w/index">10 str w/index</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE MATCH(cf_aa) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ab) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ac) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ad) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ae) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_af) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ag) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ah) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ai) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_aj) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 0.423843, 0.422772, 0.42497, 0.428438, 0.426967, 0.42995</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>fulltext</td>
<td>cf_aa,cf_ab,cf_ac,cf_ad,cf_ae,cf_af,cf_ag,cf_ah,cf_ai,cf_aj</td>
<td>cf_aa</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str d1, distcol_str d2, distcol_str d3, distcol_str d4, distcol_str d5, distcol_str d6, distcol_str d7, distcol_str d8, distcol_str d9, distcol_str d10 WHERE d1.bug_id = d2.bug_id AND d2.bug_id = d3.bug_id AND d3.bug_id = d4.bug_id AND d4.bug_id = d5.bug_id AND d5.bug_id = d6.bug_id AND d6.bug_id = d7.bug_id AND d7.bug_id = d8.bug_id AND d8.bug_id = d9.bug_id AND d9.bug_id = d10.bug_id AND d1.field_id = 0 AND d2.field_id = 1 AND d3.field_id = 2 AND d4.field_id = 3 AND d5.field_id = 4 AND d6.field_id = 5 AND d7.field_id = 6 AND d8.field_id = 7 AND d9.field_id = 8 AND d10.field_id = 9 AND MATCH(d1.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d2.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d3.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d4.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d5.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d6.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d7.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d8.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d9.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d10.value) AGAINST ('+meta*' IN BOOLEAN MODE)</p>
<p>Times: 3.386254, 3.370839, 3.359396, 3.409458, 3.415238, 3.423428</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d1</td>
<td>fulltext</td>
<td>PRIMARY,field_id,value</td>
<td>value</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d1.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d3</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d2.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d4</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d3.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d5</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d4.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d6</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d5.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d7</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d6.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d8</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d7.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d9</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d8.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d10</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d9.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="1 int bzlike">1 int bzlike</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE cf_int1 > 500</p>
<p>Times: 3.494855, 3.480936, 3.465892, 3.549008, 3.573886, 3.566877</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>ALL</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td>300000</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM realcol JOIN distcol_int d2 ON realcol.bug_id = d2.bug_id WHERE d2.field_id = 10 AND d2.value > 500</p>
<p>Times: 5.547725, 5.248616, 5.159413, 5.193495, 5.223068, 5.179345</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>ref</td>
<td>PRIMARY,field_id</td>
<td>field_id</td>
<td>4</td>
<td>const</td>
<td>356566</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>eq_ref</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>4</td>
<td>bugs_bmo.d2.bug_id</td>
<td>1</td>
<td>Using index</td>
</tr>
</table>
<h2><a name="1 str, 1 int">1 str, 1 int</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE INSTR(cf_aa, 'meta') AND cf_int1 > 500</p>
<p>Times: 4.007655, 3.963561, 4.106177, 4.099832, 3.98221, 4.024406</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>ALL</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td>300000</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str d1, distcol_int d2 WHERE d1.bug_id = d2.bug_id AND d1.field_id = 0 AND d2.field_id = 10 AND INSTR(d1.value, 'meta') AND d2.value > 500</p>
<p>Times: 11.992551, 11.373418, 11.659763, 11.395782, 14.464244, 12.753879</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>ref</td>
<td>PRIMARY,field_id</td>
<td>field_id</td>
<td>4</td>
<td>const</td>
<td>356566</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d1</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d2.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="1 str, 1 int w/index">1 str, 1 int w/index</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE MATCH(cf_aa) AGAINST ('+meta*' IN BOOLEAN MODE) AND cf_int1 > 500</p>
<p>Times: 9.056386, 0.363944, 0.314032, 0.313341, 0.314408, 0.308338</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>fulltext</td>
<td>cf_aa</td>
<td>cf_aa</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str d1, distcol_int d2 WHERE d1.bug_id = d2.bug_id AND d1.field_id = 0 AND d2.field_id = 10 AND MATCH(d1.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND d2.value > 500</p>
<p>Times: 10.442345, 3.746491, 3.215408, 3.193369, 3.215455, 3.224354</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d1</td>
<td>fulltext</td>
<td>PRIMARY,field_id,value</td>
<td>value</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d1.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="2 str, 2 int">2 str, 2 int</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE INSTR(cf_aa, 'meta') AND instr(cf_ab, 'meta') AND cf_int1 > 500 AND cf_int2 > 500</p>
<p>Times: 4.749205, 4.097737, 4.09643, 3.979339, 3.997275, 4.047099</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>ALL</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td>300000</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str d1, distcol_str d2, distcol_int d3, distcol_int d4 WHERE d1.bug_id = d2.bug_id AND d2.bug_id = d3.bug_id AND d3.bug_id = d4.bug_id AND d1.field_id = 0 AND d2.field_id = 1 AND d3.field_id = 10 AND d4.field_id = 11 AND INSTR(d1.value, 'meta') AND INSTR(d2.value, 'meta') AND d3.value > 500 AND d4.value > 500</p>
<p>Times: 13.740489, 11.576691, 10.686316, 10.636776, 10.538271, 10.625853</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d4</td>
<td>ref</td>
<td>PRIMARY,field_id</td>
<td>field_id</td>
<td>4</td>
<td>const</td>
<td>243432</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d3</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d4.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d3.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d1</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d2.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="2 str, 2 int w/index">2 str, 2 int w/index</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT COUNT(*) FROM realcol WHERE MATCH(cf_aa) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(cf_ab) AGAINST ('+meta*' IN BOOLEAN MODE) AND cf_int1 > 500 AND cf_int2 > 500</p>
<p>Times: 0.405908, 0.403199, 0.401663, 0.400662, 0.404356, 0.401555</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>realcol</td>
<td>fulltext</td>
<td>cf_aa,cf_ab</td>
<td>cf_aa</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT COUNT(*) FROM distcol_str d1, distcol_str d2, distcol_int d3, distcol_int d4 WHERE d1.bug_id = d2.bug_id AND d2.bug_id = d3.bug_id AND d3.bug_id = d4.bug_id AND d1.field_id = 0 AND d2.field_id = 1 AND d3.field_id = 10 AND d4.field_id = 11 AND MATCH(d1.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND MATCH(d2.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND d3.value > 500 AND d4.value > 500</p>
<p>Times: 15.194209, 4.327783, 3.46561, 3.347815, 3.388783, 3.406913</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d1</td>
<td>fulltext</td>
<td>PRIMARY,field_id,value</td>
<td>value</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d2</td>
<td>eq_ref</td>
<td>PRIMARY,field_id,value</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d1.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d3</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d2.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>d4</td>
<td>eq_ref</td>
<td>PRIMARY,field_id</td>
<td>PRIMARY</td>
<td>8</td>
<td>bugs_bmo.d3.bug_id,const</td>
<td>1</td>
<td>Using where</td>
</tr>
</table>
<h2><a name="simple b.m.o query">simple b.m.o query</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT bugs.bug_id, bugs.bug_severity, bugs.priority, bugs.bug_status, bugs.resolution, bugs.bug_severity, bugs.priority, bugs.rep_platform, map_assigned_to.login_name, bugs.bug_status, bugs.resolution, bugs.short_desc FROM bugs, profiles AS map_assigned_to LEFT JOIN bug_group_map ON bug_group_map.bug_id = bugs.bug_id WHERE bugs.assigned_to = map_assigned_to.userid AND ((INSTR(LOWER(bugs.status_whiteboard), 'meta'))) AND ((bug_group_map.group_id IS NULL)) GROUP BY bugs.bug_id ORDER BY bugs.bug_id</p>
<p>Times: 3.097772, 1.918027, 1.891525, 1.883466, 1.88389, 1.881021</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bugs</td>
<td>ALL</td>
<td>assigned_to</td>
<td></td>
<td></td>
<td></td>
<td>277581</td>
<td>Using where; Using temporary; Using filesort</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>map_assigned_to</td>
<td>eq_ref</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>3</td>
<td>bugs_bmo.bugs.assigned_to</td>
<td>1</td>
<td></td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bug_group_map</td>
<td>ref</td>
<td>bug_id</td>
<td>bug_id</td>
<td>3</td>
<td>bugs_bmo.bugs.bug_id</td>
<td>16</td>
<td>Using where; Using index; Not exists</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT bugs.bug_id, bugs.bug_severity, bugs.priority, bugs.bug_status, bugs.resolution, bugs.bug_severity, bugs.priority, bugs.rep_platform, map_assigned_to.login_name, bugs.bug_status, bugs.resolution, bugs.short_desc FROM bugs, profiles AS map_assigned_to LEFT JOIN bug_group_map ON bug_group_map.bug_id = bugs.bug_id JOIN distcol_str ON bugs.bug_id = distcol_str.bug_id WHERE bugs.assigned_to = map_assigned_to.userid AND distcol_str.field_id = 11 AND ((INSTR(LOWER(distcol_str.value), 'meta'))) AND ((bug_group_map.group_id IS NULL)) GROUP BY bugs.bug_id ORDER BY bugs.bug_id</p>
<p>Times: 0.693887, 0.485614, 0.488777, 0.488512, 0.490227, 0.489969</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>distcol_str</td>
<td>ref</td>
<td>PRIMARY,field_id</td>
<td>field_id</td>
<td>4</td>
<td>const</td>
<td>86968</td>
<td>Using where; Using temporary; Using filesort</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bugs</td>
<td>eq_ref</td>
<td>PRIMARY,assigned_to</td>
<td>PRIMARY</td>
<td>3</td>
<td>bugs_bmo.distcol_str.bug_id</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>map_assigned_to</td>
<td>eq_ref</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>3</td>
<td>bugs_bmo.bugs.assigned_to</td>
<td>1</td>
<td></td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bug_group_map</td>
<td>ref</td>
<td>bug_id</td>
<td>bug_id</td>
<td>3</td>
<td>bugs_bmo.bugs.bug_id</td>
<td>16</td>
<td>Using where; Using index; Not exists</td>
</tr>
</table>
<h3>Real Distributed</h3>
<p>Query: SELECT bugs.bug_id, bugs.bug_severity, bugs.priority, bugs.bug_status, bugs.resolution, bugs.bug_severity, bugs.priority, bugs.rep_platform, map_assigned_to.login_name, bugs.bug_status, bugs.resolution, bugs.short_desc FROM bugs, profiles AS map_assigned_to LEFT JOIN bug_group_map ON bug_group_map.bug_id = bugs.bug_id JOIN status_whiteboard ON bugs.bug_id = status_whiteboard.bug_id WHERE bugs.assigned_to = map_assigned_to.userid AND ((INSTR(LOWER(status_whiteboard.status_whiteboard), 'meta'))) AND ((bug_group_map.group_id IS NULL)) GROUP BY bugs.bug_id ORDER BY bugs.bug_id</p>
<p>Times: 0.124238, 0.095352, 0.094975, 0.096168, 0.099798, 0.096786</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>status_whiteboard</td>
<td>ALL</td>
<td></td>
<td></td>
<td></td>
<td></td>
<td>33013</td>
<td>Using where; Using temporary; Using filesort</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bugs</td>
<td>eq_ref</td>
<td>PRIMARY,assigned_to</td>
<td>PRIMARY</td>
<td>3</td>
<td>bugs_bmo.status_whiteboard.bug_id</td>
<td>1</td>
<td></td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>map_assigned_to</td>
<td>eq_ref</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>3</td>
<td>bugs_bmo.bugs.assigned_to</td>
<td>1</td>
<td></td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bug_group_map</td>
<td>ref</td>
<td>bug_id</td>
<td>bug_id</td>
<td>3</td>
<td>bugs_bmo.bugs.bug_id</td>
<td>16</td>
<td>Using where; Using index; Not exists</td>
</tr>
</table>
<h2><a name="simple b.m.o query w/index">simple b.m.o query w/index</a></h2>
<p></p>
<h3>Real</h3>
<p>Query: SELECT bugs.bug_id, bugs.bug_severity, bugs.priority, bugs.bug_status, bugs.resolution, bugs.bug_severity, bugs.priority, bugs.rep_platform, map_assigned_to.login_name, bugs.bug_status, bugs.resolution, bugs.short_desc FROM bugs, profiles AS map_assigned_to LEFT JOIN bug_group_map ON bug_group_map.bug_id = bugs.bug_id WHERE bugs.assigned_to = map_assigned_to.userid AND MATCH(status_whiteboard) AGAINST ('+meta*' IN BOOLEAN MODE) AND ((bug_group_map.group_id IS NULL)) GROUP BY bugs.bug_id ORDER BY bugs.bug_id</p>
<p>Times: 0.029212, 0.008343, 0.007996, 0.007983, 0.008251, 0.008012</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bugs</td>
<td>fulltext</td>
<td>assigned_to,status_whiteboard</td>
<td>status_whiteboard</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where; Using temporary; Using filesort</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>map_assigned_to</td>
<td>eq_ref</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>3</td>
<td>bugs_bmo.bugs.assigned_to</td>
<td>1</td>
<td></td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bug_group_map</td>
<td>ref</td>
<td>bug_id</td>
<td>bug_id</td>
<td>3</td>
<td>bugs_bmo.bugs.bug_id</td>
<td>16</td>
<td>Using where; Using index; Not exists</td>
</tr>
</table>
<h3>Distributed</h3>
<p>Query: SELECT bugs.bug_id, bugs.bug_severity, bugs.priority, bugs.bug_status, bugs.resolution, bugs.bug_severity, bugs.priority, bugs.rep_platform, map_assigned_to.login_name, bugs.bug_status, bugs.resolution, bugs.short_desc FROM bugs, profiles AS map_assigned_to LEFT JOIN bug_group_map ON bug_group_map.bug_id = bugs.bug_id JOIN distcol_str ON bugs.bug_id = distcol_str.bug_id WHERE bugs.assigned_to = map_assigned_to.userid AND distcol_str.field_id = 11 AND MATCH(distcol_str.value) AGAINST ('+meta*' IN BOOLEAN MODE) AND ((bug_group_map.group_id IS NULL)) GROUP BY bugs.bug_id ORDER BY bugs.bug_id</p>
<p>Times: 27.62224, 6.338093, 3.176355, 2.954995, 2.955385, 2.952455</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>distcol_str</td>
<td>fulltext</td>
<td>PRIMARY,field_id,value</td>
<td>value</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where; Using temporary; Using filesort</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bugs</td>
<td>eq_ref</td>
<td>PRIMARY,assigned_to</td>
<td>PRIMARY</td>
<td>3</td>
<td>bugs_bmo.distcol_str.bug_id</td>
<td>1</td>
<td>Using where</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>map_assigned_to</td>
<td>eq_ref</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>3</td>
<td>bugs_bmo.bugs.assigned_to</td>
<td>1</td>
<td></td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bug_group_map</td>
<td>ref</td>
<td>bug_id</td>
<td>bug_id</td>
<td>3</td>
<td>bugs_bmo.bugs.bug_id</td>
<td>16</td>
<td>Using where; Using index; Not exists</td>
</tr>
</table>
<h3>Real Distributed</h3>
<p>Query: SELECT bugs.bug_id, bugs.bug_severity, bugs.priority, bugs.bug_status, bugs.resolution, bugs.bug_severity, bugs.priority, bugs.rep_platform, map_assigned_to.login_name, bugs.bug_status, bugs.resolution, bugs.short_desc FROM bugs, profiles AS map_assigned_to LEFT JOIN bug_group_map ON bug_group_map.bug_id = bugs.bug_id JOIN status_whiteboard ON bugs.bug_id = status_whiteboard.bug_id WHERE bugs.assigned_to = map_assigned_to.userid AND MATCH(status_whiteboard.status_whiteboard) AGAINST ('+meta*' IN BOOLEAN MODE) AND ((bug_group_map.group_id IS NULL)) GROUP BY bugs.bug_id ORDER BY bugs.bug_id</p>
<p>Times: 0.029906, 0.010184, 0.009634, 0.010228, 0.010004, 0.009582</p>
<table border="1">
<caption>Explanation</caption>
<tr>
<th>id</th>
<th>select_type</th>
<th>table</th>
<th>type</th>
<th>possible_keys</th>
<th>key</th>
<th>key_len</th>
<th>ref</th>
<th>rows</th>
<th>Extra</th>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>status_whiteboard</td>
<td>fulltext</td>
<td>status_whiteboard</td>
<td>status_whiteboard</td>
<td>0</td>
<td></td>
<td>1</td>
<td>Using where; Using temporary; Using filesort</td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bugs</td>
<td>eq_ref</td>
<td>PRIMARY,assigned_to</td>
<td>PRIMARY</td>
<td>3</td>
<td>bugs_bmo.status_whiteboard.bug_id</td>
<td>1</td>
<td></td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>map_assigned_to</td>
<td>eq_ref</td>
<td>PRIMARY</td>
<td>PRIMARY</td>
<td>3</td>
<td>bugs_bmo.bugs.assigned_to</td>
<td>1</td>
<td></td>
</tr>
<tr>
<td>1</td>
<td>SIMPLE</td>
<td>bug_group_map</td>
<td>ref</td>
<td>bug_id</td>
<td>bug_id</td>
<td>3</td>
<td>bugs_bmo.bugs.bug_id</td>
<td>16</td>
<td>Using where; Using index; Not exists</td>
</tr>
</table>
</body>
</html>