Type SQL
in this code Type SQL "" I do not receive a more detailed type for weight and dimensions and only JsonValue
5 Replies
You chose to debug with a human. They'll tinker with your query soon. If you get curious meanwhile, hop into
#ask-ai
for a quick spin!#ask-ai
Can you please elaborate? I didn't get your question.
JSON is by default not typed: https://github.com/prisma/prisma/issues/3219
You need to use an external package like to type JSON fields:
https://www.npmjs.com/package/prisma-json-types-generator
GitHub
Define type of content of
Json
field · Issue #3219 · prisma/prismaProblem Right now if you have the following schema with Json field: model User { id Int @default(autoincrement()) @id name String? extendedProfile Json } You'll end up with a problem that you d...
npm
prisma-json-types-generator
Changes JsonValues to your custom typescript type. Latest version: 3.5.2, last published: 7 days ago. Start using prisma-json-types-generator in your project by running
npm i prisma-json-types-generator
. There are 10 other projects in the npm registry using prisma-json-types-generator.GitHub
Improving SQL Type Definitions · Issue #27904 · prisma/prisma
Bug description In this code Type SQL getProductVariants.sql: -- @param {String} $1:productId -- @param {Int} $2:pageIndex -- @param {Int} $3:pageSize -- @param {String} $4:sortBy -- @param {String...
Thanks for creating the issue!