Dean Gibson (DB Administrator) wrote:
Then I don't understand. While I've never used MySQL, the MySQL web
pages apparently indicate that VARCHAR has been supported since version
3.2: http://dev.mysql.com/doc/refman/4.1/en/char.html
Only in DDL and not the cast function, apparently. Mysql 5.1 says:
select cast(123 AS varchar)
or
select cast(123 AS varchar(10))
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 'varchar)'
at line 1.
---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
choose an index scan if your joining column's datatypes do not
match