drizzle-orm
drizzle-orm copied to clipboard
Add support for Maria DB (core API implementation)
(Partially) Addresses #203.
This PR aims to add support for Maria DB, which simply extends the existent MySQL dialect.
Tasks:
- [x] Implement mariadb driver.
- [x] Write core API integration tests for the
mariadb
driver.
Other changes implemented:
- Remove
fullJoin
from MySQL dialect, as neither MySQL nor Maria DB support full joins. - Update Drizzle Kit version in the workspace.
Things maybe worth mentioning:
-
int auto_increment
is used when creating tables in integration tests instead ofserial
because the latter creates abigint
in Maria DB. - When creating an instance of
MySqlDatabase
using themariadb
driver, Planetscale mode is used by default as Maria DB doesn't supportleft join lateral
. (Maria DB Issue).
By removing fullJoin
from MySQL dialect, #1125 is also addressed.
Due to issues I've discussed with the Drizzle team, this PR will only aim to provide MariaDB support with the core API, which means that RQB will come later and will likely be addressed in a separate PR.
@L-Mario564 Updates?
@Creative-Difficulty Haven't heard anything from the Drizzle Team. They knew about this PR when I was done adding commits to it in December, but right now I don't know what's the status for adding MariaDB support.
@drizzle-team
@drizzle-team
This issue has 8 +1's and 14 hearts. The code has been written and @drizzle-team/@dankochetov potentially only needs to merge it. Wonder why this isn't this getting any attention?
This issue has 8 +1's and 14 hearts. The code has been written and @drizzle-team/@dankochetov potentially only needs to merge it. Wonder why this isn't this getting any attention?
I can bring the Drizzle Team's attention to this PR, although keep in mind there's a lot of other stuff being worked on, including a new dialect (MSSQL), so I can't promise how soon this will be reviewed/merged.
maybe they should consider mariadb connector instead of mysql2, which is simply faster.
Can we get some attention for this issue again? Me personally, I prefer postgres over everything, but one company expects our team to use mariadb as the database, but the normal mysql2
driver has a few problems. It would be nice if the native mariadb nodejs driver would be also supported in drizzle-orm. This way the most used databases would be covered. And I guess it should not take too much time, especially because some/most of the code is already written here. (Although I have no idea of this codebase, so it might be, that there is much more to do)
Could you @AndriiSherman perhaps give some initial feedback so the submitter @L-Mario564 can iterate and finalize this for merging?
Any reason this hasn't gone through yet?
Just to give everyone an update, the team is working on polishing the existing drivers and dialects before integrating any new ones. Do expect this to be merged before Drizzle ORM v1 though.