Hi Øystein,
thank you for approval.
On 17.06.11 12.23, Øystein Grøvlen wrote:
> Approved, with the following suggestions:
>
> - Simplify test case
I am not able to simplify the test case very much.
Number of rows in table t1 reduced from 10 to 4.
Tried to replace the Innodb table with a storage engine independent table, but
then I would get a bunch of warnings that I did not like.
Large indexed field col_varchar_1024_utf8_key is required, otherwise the
MaterializeScan strategy is not chosen.
> - Add EXPLAIN
Done.
>
> --
> Øystein
>
> On 16/06/2011 12:56, Roy Lyseng wrote:
>> #At file:///home/rl136806/mysql/repo/mysql-review/ based on
>> revid:jorgen.loland@stripped
>>
>> 3385 Roy Lyseng 2011-06-16
>> Bug#12640083: Same query executed as WHERE subquery gives different
>> results on IN() compare
>>
>> The query that returns with an empty result is using the
>> MaterializeScan semi-join strategy, and it has an outer join
>> operation inside the materialized subquery. As has happened before,
>> there are remnants of outer join execution in the join_tab that is
>> reused for reading the materialized tables, in this case it was the
>> first_unmatched field that needed clearing.
>>
>> mysql-test/include/subquery_sj.inc
>> Added test case for bug#12640083.
>>
>> mysql-test/r/subquery_sj_all.result
>> mysql-test/r/subquery_sj_all_jcl6.result
>> mysql-test/r/subquery_sj_all_jcl7.result
>> mysql-test/r/subquery_sj_dupsweed.result
>> mysql-test/r/subquery_sj_dupsweed_jcl6.result
>> mysql-test/r/subquery_sj_dupsweed_jcl7.result
>> mysql-test/r/subquery_sj_firstmatch.result
>> mysql-test/r/subquery_sj_firstmatch_jcl6.result
>> mysql-test/r/subquery_sj_firstmatch_jcl7.result
>> mysql-test/r/subquery_sj_loosescan.result
>> mysql-test/r/subquery_sj_loosescan_jcl6.result
>> mysql-test/r/subquery_sj_loosescan_jcl7.result
>> mysql-test/r/subquery_sj_mat.result
>> mysql-test/r/subquery_sj_mat_jcl6.result
>> mysql-test/r/subquery_sj_mat_jcl7.result
>> mysql-test/r/subquery_sj_mat_nosj.result
>> mysql-test/r/subquery_sj_none.result
>> mysql-test/r/subquery_sj_none_jcl6.result
>> mysql-test/r/subquery_sj_none_jcl7.result
>> Added test case result for bug#12640083.
>>
>> sql/sql_select.cc
>> In sub_select_sjm(), cleared the flag last_tab->first_unmatched.
>>
>
> ...