List:Commits« Previous MessageNext Message »
From:Roy Lyseng Date:June 24 2011 1:30pm
Subject:Re: bzr commit into mysql-trunk branch (guilhem.bichot:3386) Bug#12668294
View as plain text  
On 24.06.11 15.21, Guilhem Bichot wrote:
> Hello,
>
> Roy Lyseng a écrit, Le 22.06.2011 16:59:
>> Hi Guilhem,
>>
>> this bugfix is approved, I have just a comment comment below.
>
>>> === modified file 'mysql-test/include/subquery_mat.inc'
>>> --- a/mysql-test/include/subquery_mat.inc 2011-04-01 11:06:48 +0000
>>> +++ b/mysql-test/include/subquery_mat.inc 2011-06-20 14:29:59 +0000
>>> @@ -882,3 +882,32 @@ DROP TABLE t1, t2;
>>> DROP VIEW v3;
>>>
>>> --echo # End Bug#11852644
>>> +
>>> +--echo
>>> +--echo # Bug#12668294 - GROUP BY ON EMPTY RESULT GIVES EMPTY ROW
>>> +--echo # INSTEAD OF NULL WHEN MATERIALIZATION ON
>>> +--echo
>>> +
>>> +CREATE TABLE t1 (col_int_nokey INT) ENGINE=MEMORY;
>>> +CREATE TABLE t2 (col_int_nokey INT) ENGINE=MEMORY;
>>> +INSERT INTO t2 VALUES (8),(7);
>>> +CREATE TABLE t3 (col_int_nokey INT) ENGINE=MEMORY;
>>> +INSERT INTO t3 VALUES (7);
>>> +
>>> +SELECT MIN(t3.col_int_nokey),t1.col_int_nokey AS field3
>>> +FROM t3
>>> + LEFT JOIN t1
>>> + ON t1.col_int_nokey
>>> +WHERE (194, 200) IN (
>>> + SELECT SQ4_alias1.col_int_nokey,
>>> + SQ4_alias2.col_int_nokey
>>> + FROM t2 AS SQ4_alias1
>>> + JOIN
>>> + t2 AS SQ4_alias2
>>> + ON SQ4_alias2.col_int_nokey = 5
>>> + )
>>> +GROUP BY field3 ;
>>
>> t1.col_int_nokey in the SELECT list makes the query non-deterministic (even
>> though this is not a big issue for a single-row query).
>
> I think it's deterministic because there is GROUP BY field3, and field3 is the
> alias for t1.col_int_nokey.
> Order of rows in result may not be deterministic, but let's not care, it's just
> one row.

Sorry! Too many reviews recently, obviously...

Thanks,
Roy
Thread
bzr commit into mysql-trunk branch (guilhem.bichot:3386) Bug#12668294Guilhem Bichot20 Jun
  • Re: bzr commit into mysql-trunk branch (guilhem.bichot:3386) Bug#12668294Roy Lyseng23 Jun
    • Re: bzr commit into mysql-trunk branch (guilhem.bichot:3386) Bug#12668294Guilhem Bichot25 Jun
  • Re: bzr commit into mysql-trunk branch (guilhem.bichot:3386) Bug#12668294Jorgen Loland23 Jun
    • Re: bzr commit into mysql-trunk branch (guilhem.bichot:3386) Bug#12668294Guilhem Bichot25 Jun
Re: bzr commit into mysql-trunk branch (guilhem.bichot:3386) Bug#12668294Roy Lyseng25 Jun