PostgreSQL to MySQL Migration

SQLines tools can help you transfer data, convert database schema (DDL), views, stored functions (procedures), triggers, queries and SQL scripts from PostgreSQL to MySQL.

Databases:

  • PostgreSQL 18.x, 17.x, 16.x, 15.x, 14.x, 13.x, 12.x, 11.x, 10.x and 9.x
  • MySQL 9.x, 8.x and 5.x

Migration Reference

Data Types

Converting date and time data types:

PostgreSQL MySQL
1 TIMESTAMP(p) WITH TIME ZONE Date and time with fraction and time zone DATETIME(p)

CREATE TABLE Statement

Converting CREATE TABLE statement keywords and clauses:

PostgreSQL MySQL
1 GENERATED AS IDENTITY Identity column AUTO_INCREMENT