N
N
Nazar Mokrinsky2015-03-07 14:52:18
PHP
Nazar Mokrinsky, 2015-03-07 14:52:18

MySQL > PgSQL, conversion on the fly?

I'm looking for a library that could translate at least the basic syntax of MySQL queries into PostgreSQL on the fly.
There are tools for converting dumps and the like, but I would like a small library for converting on the fly.
I searched with a search engine, on GitHub, packagist - nothing suitable was found, maybe someone saw this?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
O
OnYourLips, 2015-03-07
@OnYourLips

The basic syntax is already compatible.
But something more complicated will not work out, and the point is not that such a converter cannot be written, but that the behavior of the DBMS will be different.
For example, PostgreSQL will swear at some MySQL queries as invalid, even if the syntax is correct.

P
Puma Thailand, 2015-03-07
@opium

This is not possible because the possibilities and syntax are different and there is no unambiguous conversion.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question