PostgreSQL-For-Wordpress / postgresql-for-wordpress

A maintained fork of https://wordpress.org/plugins/postgresql-for-wordpress/
GNU General Public License v2.0
220 stars 71 forks source link

Version 4 branch should not use regex #45

Open mattbucci opened 10 months ago

mattbucci commented 10 months ago

Investigate the same approach as the WordPress SQLite implemention https://github.com/phpmyadmin/sql-parser

https://wordpress.org/plugins/sqlite-database-integration/

Simplified structure regardless can look something like:

WPDB -> monkey patched mySQL functions -> parser / regex/ variable extraction -> parsed MySQL representation (class or struct) -> convert to Postgres representation -> toSQL() method -> execute against postgres database <-- post process postgres output <-- return data to WPDB