nikolasburk
Json data in Prisma Client
When querying data, you can now perform basic filtering with Json fields using equal and not. Check out the release notes for an example.
🙈 Hide the Prisma CLI Update Message
You can now hide the Prisma CLI update notifier message by setting the environment variable PRISMA_HIDE_UPDATE_MESSAGE (e.g. to "1", "true" or "asd").
⚡*️ Prepared statement caching for PostgreSQL*
Under the hood, we enabled prepared statement caching for PostgreSQL. This way Prisma Client's query engine does not repeatedly prepare the same statement but can reuse an existing one which reduces database CPU usage and query latency.
🐛 Many bug fixes for Prisma VSCode Extension
The Prisma VSCode extension received an extraordinary number of tiny fixes this release, which will make using it much more pleasant.
🧪 Experimental features
From this release onwards, we'll enable experimental features that you can explicitly opt-in to! Note that these features are not part of your official and stable API and may be changed or removed completely in a future release.
Experimental features in Prisma Client can be enabled via the experimentalFeatures field on the generator definition in your Prisma schema. In this release, two new experimental features are released:
• `connectOrCreate`: A new query option similar to upsert but used inside of nested writes (issue)
• `transactionApi`: Enables a new transaction function in Prisma Client that lets you execute multiple write operations wrapped in a transaction (issue)
Here is how you can enable them for your Prisma Client:
generator client {
provider = "prisma-client-js"
experimentalFeatures = ["connectOrCreate", "transactionApi"]
}
Be sure to run npx prisma generate after you've added these fields to update your generated Prisma Client.
To enable experimental features in the Prisma CLI, you need to add explicit experimental flags when running a command. This Prisma release contains an experimental feature for the prisma introspect command that keeps your manual changes in the Prisma schema after you re-introspect your database (e.g. @map and @@map attributes and relation field names). If you want to try out this functionality, you need to add the --experimental-reintrospection flag to the prisma introspect command:
npx prisma introspect
You can learn more about all features in the release notes, we're looking forward to your feedback for the new version! 🙌 😄