XF 2.0 Will XF2 support other databases than mysql?

DragonByte Tech

Well-known member
The biggest problem that I can see with having XF2 support other databases (disregarding the added support workload from people who heard that $dbSystem is faster than MySQL but they don't know how to admin it *cough*nginx*/cough*) is the fact that XF2 still allows direct queries to be executed (and probably relies on it in more than a few locations).

Direct DB queries are supported because there's some operations that require a query so arcane even Merlin would be confused, in order to not murder your site with multiple queries (or a worse performing query). You just can't translate queries like that to a "query builder" type system, unless you create something that's very difficult to use for developers (even the developers who wrote the bloody thing).

On the opposite end of the spectrum, there are some queries that are so fast and small that setting up a (potentially huge) Query Builder object just to delete a single record is a complete waste of memory and CPU cycles, which punishes people on shared hosts.

"But Fillip", I hear you ask, "can't you just create a mapping file that lets developers write their queries for each DBMS and have XF2 load the appropriate file?"

Congratulations, you've now created a system that is going to be 100% un-used by every amateur developer (they don't know what "postgres" is or how to install it on their machines), and will probably alienate a fair number of them. If you think that addon developers are going to be happy with even a single support ticket from someone saying "I tried to run this addon on postgres and I now have approx. eleventy bajillion errors in my logs, nothing is working. I want my money back.", then you would be mistaken :p

I'm sure a lot of developers would be perfectly fine with having to rewrite their queries to use a query builder, but the XF2 dev team will have to take the other developers into consideration too when deciding whether it's actually worth bothering.

If there's 1000 developers out there and let's say 75% of them are hobby developers who wrote something cool for their site and decided to give back to the community, then the pressure from people wanting other DBMS support would need to outweigh the loss of up to 750 contributors and the bad word-of-mouth those (up to) 750 hobby developers would (potentially) produce.

I'm sure there's quite a number of other factors the XF team could come up with as well :)


Liam W

Well-known member
While I know of PostgreSQL, I’ve no idea how to use it. Even a simple update query on my GitLab instance involved a google... I just don’t see the point in having to learn another DBMS and then having to debug 2 systems.