You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This issue has been automatically marked as stale because it has been open 360 days with no activity. Remove stale label or comment or this will be closed in 180 days
Your Question
I have the following set of GORM models, with 2 orders of one-to-many relations:
When I attempt to insert data as follows, I get the error
pq: insert or update on table "albums" violates foreign key constraint "fk_orders_albums"
.The document you expected this should be explained
I followed the steps in the Has Many page of the docs, to no avail.
Expected answer
What might I be doing wrong here? Thank you!
The text was updated successfully, but these errors were encountered: