CONVERT() broken in 4.1.1?

Kevin Day <[email protected]>
Newsgroups gmane.comp.db.mysql.bugs
Message-ID <[email protected]>
This worked in 4.0:

mysql> SELECT CONVERT(NOW(), DATE);
+----------------------+
| CONVERT(NOW(), DATE) |
+----------------------+
| 2004-01-16 18:12:18  |
+----------------------+
1 row in set (0.00 sec)

And even in 4.1.0, but in 4.1.1 it returns:

mysql> SELECT CONVERT(NOW(), DATE);
ERROR 1064: You have an error in your SQL syntax.  Check the manual 
that corresponds to your MySQL server version for the right syntax to 
use near ')' at line 1


However, replacing it with CAST() works fine:

mysql> select CAST(NOW() AS DATE);
+---------------------+
| CAST(NOW() AS DATE) |
+---------------------+
| 2004-01-17          |
+---------------------+
1 row in set (0.00 sec)


However, there is a small difference between 4.0 and 4.1 here. 4.0 
returns it as a date and time, 4.1 returns it as just the date (as 
would be expected?)


Sorry if this has been reported before, but I couldn't find any mention 
of this anywhere.
smime.p7s (application/pkcs7-signature, 2.3 KB) - not displayed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.