Where can I learn more about Prisma or data modeling?

RedwoodJS uses Prisma, a next generation ORM, to talk to a database.

Prisma Benefits

What’s nice about Prisma is that it helps you not only connect to a database, but it also:

  • Defines your schema
  • Runs migrations
  • Seeds your database
  • Digs into the data with its built-in studio
  • Offers friendly way to query/update data without having to write complex SQL
    • This is great for nested reads or writes where you might have to do complicated joins.
    • You can always write raw (but safe) SQL to execute any query or update you may need to.
    • You like CTE’s right?

Pick Your Database of Choice

Prisma also gives you choice of databases without having to change how you access it. There are some differences, but for all intents and purposes switching from MySQL to Postgres is painless.

It supports Postgres, MySQL, SQLite, MongoDB, PlanetScale, SQL Server, and CockroachDB. Which database do I choose – that’s another topic, but Postgres is a solid choice.

Learn More

2 Likes