# Native Database Protocol Support

Solves - "I need a transparent, sever-only MySQL/MariaDB or PostgreSQL proxy with features like Connection Pooling, Throttling, High Availability, Query Routing, Query Filtering, and Connection Schedules" and "I wrote my app using the native MySQL/MariaDB/PostgreSQL API but the company is migrating to Oracle. I can tweak the queries to work with Oracle but I really don't want to have to modify the app to use OCI."

Native database apps communicate with the database using native database client-server protocols.

For example, MySQL/MariaDB apps communicate with the database using the MySQL/MariaDB client-server protocol:

...and PostgreSQL apps communicate with the database using the PostgreSQL client-server protocol:

Whether written using the native SQL Relay API or a connector of some sort, SQL Relay apps generally communicate with SQL Relay using the SQL Relay client-server protocol:

However, SQL Relay also supports the MySQL/MariaDB and PostgreSQL client-server protocols. This allows apps written for those databases to communicate with SQL Relay, rather than directly with the native database, without modification.

In this configuration, SQL Relay becomes a transparent proxy. Native apps aimed at SQL Relay still think that they're talking to the database, but in fact, are talking to SQL Relay. Once the app is talking to SQL Relay, most of SQL Relay's features become available to the app, including Connection Pooling, Throttling, High Availability, Query Routing, Query Filtering, and Connection Schedules. Since SQL Relay supports a variety of database backends, the app can also be redirected to any of these databases, instead of the database it was originally written to use.

Some queries may have to be modified to use the syntax of the new database and some code may need to be changed, but a full rewrite of the app should not be necessary.