From: Michael Widenius Date: March 19 1999 6:10pm Subject: bug in CURDATE()? List-Archive: http://lists.mysql.com/mysql/628 Message-Id: <14066.37533.920717.714251@monty.pp.sci.fi> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit >>>>> "h" == h radners writes: >> Description: h> CURDATE() in string-context gives wrong year. >> How-To-Repeat: h> SELECT SYSDATE(); => 1999-03-19 14:37:58 => OK h> SELECT CURDATE()+0; => 19990319 => OK h> SELECT CURDATE(); => 6703-03-19 => WRONG >> Originator: Horst-W. Radners >> Organization: h> IWiS GmbH, Markgrafenstr. 11, D-10969 Berlin h> Tel.: +49 30 253769-12, Fax.: -77, e-mail: h.radners@stripped >> MySQL support: none >> Synopsis: CURDATE() in string-context gives wrong year. >> Severity: serious >> Priority: medium >> Category: mysql >> Class: sw-bug >> Release: mysql-3.22.20a (Source distribution) >> Environment: h> System: IRIX 6.2 IP22 Hi! Testing... mysql> SELECT CURDATE(); +------------+ | CURDATE() | +------------+ | 1999-03-19 | +------------+ 1 row in set (0.00 sec) mysql> SELECT CURDATE()+0; +-------------+ | CURDATE()+0 | +-------------+ | 19990319 | +-------------+ Any change you know gdb good enough to debug this ? (This may be a gcc bug ...) If you can put a breakpoint at: Item_date::str and single step through this function, you should be able to find out what's wrong ? Regards, Monty