On Tue, Apr 30, 2024, at 4:50 PM, Arvids Godjuks wrote: > Hello, > > I'm splitting this discussion from https://externals.io/message/123183, > see details at https://externals.io/message/123183#123234 and > https://externals.io/message/123183#123236 to keep the original thread > clean. > > There's a clear divergence in functionality between MySQL and MariaDB. > As PDO evolves to accommodate database-specific drivers, it's sensible > to introduce a MariaDB alias for the MySQL driver. Although the mysqlnd > library handles networking protocols for both, practical higher level > usage increasingly demands differentiation at the database layer, much > like Doctrine's recent updates requiring distinct identification of > MariaDB vs. MySQL. > > I propose establishing a MariaDB namespace. This would allow for > explicit implementation of database-specific functions and help in > correctly mapping methods and queries to the respective database. > > Thoughts? Questions?
I agree with this. Even if the wire protocol isn't different right now, the SQL syntax is. Giving a "native" hook point for people to vary their DB is useful, and sets us up for when there are wire or parser differences later. Bear in mind that MySQL now also has the mysqlx protocol, which is basically a native query builder that bypasses an SQL string entirely. MariaDB has no such thing. I don't know how that would play into PDO at all, but this sort of split would give us a natural starting point to figure that out in the future. --Larry Garfield