Hi everyone🖐, I am curios to know which database does the RedwoodJS community used while developing in RedwoodJS and whether it is in production already.
I know that RedwoodJS is using Prisma, hence RedwoodJS can only works well with SQLite, MySql and PostgreSQL right?
For the most part people are using Postgres on Heroku or another major Postgres provider like Azure and other Postgres like things such as Supabase. But it really depends what you mean by “works well with.”
Prisma gives you a lot of extra functionality that you would expect from a query builder or ORM but some developers are fine just writing raw queries for their database.
Redwood can be fairly easily hooked up to any database that has a GraphQL API such as FaunaDB and really any database with a JavaScript driver can be wired up to Redwood. There has also been discussion around JSON databases like LowDB.
I recently switched over to Postgres from MySQL/MariaDB mainly because of this (technical details here).
I roll my own infrastructure in Kubernetes, but using Azure Database for MariaDB for critical things. I’ll most likely end up using Azure Database for Postgres later on. (Side note; Microsoft is really good at picking bad names for their product offerings).
If you end up using Postgres, you might find this db-reset script helpful during early prototyping. Granted, it’s not pretty but it does the job for now.
That’s a really great question, the differences between Postgres and MySQL are varied and subtle.
From a high level perspective while both are technically considered open source projects, MySQL was purchased by Oracle (Sun at the time of purchase) while Postgres has always been more of a community lead effort. That tends to nudge people one way or the other depending on how they philosophically feel about that.
At a low level, Postgres has one canonical storage engine while MySQL has many different storage engines that can be swapped out, InnoDB and MyISAM being the most common.
In terms of querying they are very similar, each follows similar variants of SQL which is why they are so commonly compared to each other.
Here are some other good resources about the differences: