Search code examples
sqlmysqlmigrationmysql5mysql4

MySQL: Migrating Queries from v4 to v5


When migrating a project from MySQL 4 to MySQL 5, what are the primary things I need to address in order to ensure queries remain compatible?

In general things should be fine, but I know that some things that worked implicitly in MySQL 4 queries have to be defined explicitly in MySQL 5 (but I can't for the life of me remember what exaxtly).


Solution

  • See http://dev.mysql.com/doc/refman/5.0/en/upgrading-from-4-1.html for a list of differences that could affect you.

    The only one I've observed is when you have a query that uses both comma-style (SQL-89) and JOIN-style syntax. Some MySQL 4.x queries must be rewritten to comply with the now more standards-compliant join semantics. See "Join Processing Changes in MySQL 5.0.12" on page http://dev.mysql.com/doc/refman/5.0/en/join.html