Not enough information to infer relation

I've defined these relation between section and item, and I'm getting "Error: There is not enough information to infer relation "public.section.item"
No description
No description
11 Replies
megamindat
megamindat6mo ago
Please help, thank you! 🙂
⚡Z.E.U.S⚡
⚡Z.E.U.S⚡6mo ago
Hey! Can you please provide your full schema?
2armedlopin
2armedlopin6mo ago
I have the same issue when upgrading to the latest version of drizzle my schema is here wondering if you are able to help https://discord.com/channels/1043890932593987624/1239600532599869613
megamindat
megamindat6mo ago
Sure, here they are:
megamindat
megamindat6mo ago
Thank you in advance. Really appreciate it. 🙂 Yeah, the latest version seems to infer relations. Did you make it to working? Stuck on this since yesterday. Any help please.
⚡Z.E.U.S⚡
⚡Z.E.U.S⚡6mo ago
@megamindat Hey! Are you having the same error? Most likely due to the fact that you did not send a complete schema, I have another one.
Error: There is not enough information to infer relation "__public__.section.subSection"
Error: There is not enough information to infer relation "__public__.section.subSection"
megamindat
megamindat6mo ago
Still the same error. If I get rid of relations in those file, it does work. There's definitely something I'm doing wrong, but don't know what. :/
megamindat
megamindat6mo ago
Thank you so much. 🙂
⚡Z.E.U.S⚡
⚡Z.E.U.S⚡6mo ago
@megamindat Found it out. You have itemRelations in item.ts and reserve_table.ts
megamindat
megamindat6mo ago
Omg, thank you so much. Copying and pasting is a bad idea. Haha Thank you so much again, it had been eating my mind. Thank you for being so helpful, this is already the third time you've helped me. ❤️
⚡Z.E.U.S⚡
⚡Z.E.U.S⚡6mo ago
Thank you for using Drizzle
Want results from more Discord servers?
Add your server