Bug #9241 Crashing with UNION and DATE() function
Submitted: 17 Mar 2005 2:43 Modified: 17 Mar 2005 2:53
Reporter: Naoki Kurosawa Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server Severity:S1 (Critical)
Version:4.1 OS:Windows (Windows XP)
Assigned to: CPU Architecture:Any

[17 Mar 2005 2:43] Naoki Kurosawa
Description:
MySQL crashes when using UNION and DATE() function.
I tried InnoDB and MyISAM table. Both of them crashed.

How to repeat:
CREATE TABLE union_crash (
  id INT NOT NULL AUTO_INCREMENT,
  date1 DATETIME,
  date2 DATETIME,
  PRIMARY KEY (id));
INSERT INTO union_crash (date1, date2) VALUES
  ('2005-1-1 11:11:11', '2005-1-2 11:11:11'),
  ('2005-1-3 11:11:11', '2005-1-4 11:11:11');

SELECT DATE(date1) FROM union_crash
UNION
SELECT DATE(date2) FROM union_crash;
[17 Mar 2005 2:53] MySQL Verification Team
Duplicate of http://bugs.mysql.com/bug.php?id=9216.

Thank you for the bug report.