Re-introspection should not remove relations when relationMode="prisma" #16130
Labels
bug/2-confirmed
Bug has been reproduced and confirmed.
kind/bug
A reported bug.
team/schema
Issue for team Schema.
topic: re-introspection
topic: referentialIntegrity/relationMode
Milestone
Bug description
Expectation based on #2221 is that the usage of relationMode="prisma" should prevent the removal of manually added relationships. This is necessary for Heroku Connect setups, where "sfid"-based relationships are not traditional FK.
However, manually added relationships appear to be automatically removed on prisma 4.5.0.
How to reproduce
(1) Using this or similar schema before introspection:
(2) run
db pull
(3) schema has had its relations removed:
Expected behavior
Manually added @relations should never be removed when using relationMode="prisma"
Prisma information
Environment & setup
Prisma Version
The text was updated successfully, but these errors were encountered: