Description
Compalex is a lightweight script that compares the schemas of two databases. It supports MySQL, Microsoft SQL Server and PostgreSQL. The easiest way to run it is with Docker, either by building your own image from the Dockerfile or by using the image on Docker Hub. You configure the two servers with environment variables. DATABASE_DRIVER selects the engine: mysql, pgsql, dblib for SQL Server, or oci for Oracle. DATABASE_HOST, DATABASE_PORT, DATABASE_NAME, DATABASE_USER and DATABASE_PASSWORD set the connection for the first server, and the _SECONDARY versions set it for the second. DATABASE_DESCRIPTION is an optional label that appears as the database name. The README explains that when a compared database runs on your own machine, the container has to reach the host machine's IP address instead of localhost, with separate steps for macOS, Windows and Linux. Default ports are 3306 for MySQL, 5432 for PostgreSQL, 1433 for SQL Server and 1521 for Oracle. You can also run it as a PHP script, which needs PHP 5.4 or newer with the PDO extension.…
Highlights
- Compares the schemas of two databases
- MySQL, SQL Server and PostgreSQL
- Docker image on Docker Hub
- Configured with environment variables
- Can run as a PHP script
Ratings & Reviews
No ratings yet
Be the first to rate Compalex.
People also visit
Compalex FAQ
What does Compalex do?
It compares the schemas of two databases so you can see how they differ.
Which databases are supported?
The README names MySQL, Microsoft SQL Server and PostgreSQL. The driver setting also lists Oracle.
How do I run it?
Use Docker, either by building the Dockerfile or pulling the image from Docker Hub, and set the database variables for your two servers.
Can I compare databases on my own machine?
Yes, but the container cannot use localhost. The README says to use the host machine's IP address, with different steps for macOS, Windows and Linux.
Can I run it without Docker?
Yes, as a PHP script. It needs PHP 5.4 or later with the PDO extension.
What are the best Compalex alternatives?
Popular alternatives to Compalex include a7 SqlTools, StackRender and data-peek. See all Compalex alternatives












