Recommend adding indices to foreign keys when referentialIntegrity = "prisma"
#992
Labels
kind/feature
A request for a new feature.
team/schema
Issue for team Schema.
topic: linting
topic: quick fix
topic: referentialIntegrity/relationMode
Milestone
Problem
See the problem in more detail here prisma/prisma#7292 (comment)
Basically, when
referentialIntegrity = "prisma"
no foreign keys are created which means no index is created. When using with PlanetScale this leads to full table scans.Suggested solution
Alternatives
Maybe there's a different way to suggest this? I'm not too familiar with all the capabilities of a VS Code plugin.
Additional context
https://briananglin.me/posts/spending-5k-to-learn-how-database-indexes-work/
The text was updated successfully, but these errors were encountered: