Commit 055ee727 authored by Michael Widenius's avatar Michael Widenius

Disable warning that comes 'occasionable' depending on if HAVING is executed or not.

parent 078f83d3
...@@ -1598,6 +1598,8 @@ CREATE TABLE `t3` ( ...@@ -1598,6 +1598,8 @@ CREATE TABLE `t3` (
) DEFAULT CHARSET=latin1; ) DEFAULT CHARSET=latin1;
INSERT INTO `t3` VALUES (1,'w'); INSERT INTO `t3` VALUES (1,'w');
# We may get warnings about 'h' not beeing a double here
--disable_warnings
SELECT SUM( DISTINCT table2 . `pk` ) AS field2 , SELECT SUM( DISTINCT table2 . `pk` ) AS field2 ,
(SELECT SUM( SUBQUERY1_t2 . `pk` ) AS SUBQUERY1_field1 (SELECT SUM( SUBQUERY1_t2 . `pk` ) AS SUBQUERY1_field1
FROM t2 AS SUBQUERY1_t2 STRAIGHT_JOIN FROM t2 AS SUBQUERY1_t2 STRAIGHT_JOIN
...@@ -1610,4 +1612,5 @@ FROM ( t1 AS table1 LEFT JOIN ...@@ -1610,4 +1612,5 @@ FROM ( t1 AS table1 LEFT JOIN
WHERE ( table1 . `pk` < 5 ) OR ( table1 . `col_varchar_key` IS NOT NULL) WHERE ( table1 . `pk` < 5 ) OR ( table1 . `col_varchar_key` IS NOT NULL)
GROUP BY field3 GROUP BY field3
HAVING (field3 <= 'h' AND field2 != 4) ; HAVING (field3 <= 'h' AND field2 != 4) ;
--enable_warnings
drop tables t1, t2, t3; drop tables t1, t2, t3;
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment