Incorrect Upsert Query used #20289
Labels
kind/improvement
An improvement to existing feature and code.
team/client
Issue for team Client.
tech/engines
Issue for tech Engines.
topic: mysql
topic: performance/queries
topic: performance
topic: upsert
nested upsert
Bug description
The Upsert query logged in Prisma is different from what Upsert actually does. It doesn't specify ON DUPLICATE KEY in query level.
Query without duplicate key
Query with duplicate key:
How to reproduce
prisma.schema
seed.ts
file and add the following seed content belowExpected behavior
Expected result should be just one query:
Prisma information
Environment & setup
Prisma Version
The text was updated successfully, but these errors were encountered: