Open janpio opened 2 years ago
Any updates on when this will get addressed? #1122 has been open for two years, yet there is no mention of this on the roadmap. I've just been bitten in the ass by this. Sure, it's my fault for not doing my due diligence on support, but I think myself and many others assumed this would be possible given how common it is to "namespace" tables under different schemas.
It's OK if this isn't a priority for the team, but I think y'all should do a better job communicating what you will or won't do. IMO, lack of multi-schema support should be in BIG bold letters, so people don't waste their time with a tool that suits their needs.
Superseded by #1122
We could ignore cross schema foreign keys during Introspection and just not render these relations. The relation scalar fields would still be present and could be set with the foreign key value manually by the user.
Sounds to me like a few lines of code, @janpio have you experimented with this workaround on a branch somewhere?
No, we are working on fixing the problem as a whole (https://github.com/prisma/prisma/issues/1122), and decided not to pursue this.
Right now Introspection of a database schema with cross schema foreign keys fails because Prisma only supports a singular schema, not querying across multiple schemas. Obviously this is planned via #1122, but as it is quite a big change there might be a possible step in between:
We could ignore cross schema foreign keys during Introspection and just not render these relations. The relation scalar fields would still be present and could bet set with the foreign key value manually by the user.