Top "Many-to-many" questions

A type of relationship between entities of types A and B which associates a list of entities of type B to an entity of type A and vice versa.

What is `related_name` used for in Django?

What is the related_name argument useful for on ManyToManyField and ForeignKey fields? For example, given the following code, what …

python django many-to-many foreign-key-relationship
Create code first, many to many, with additional fields in association table

I have this scenario: public class Member { public int MemberID { get; set; } public string FirstName { get; set; } public string LastName { …

c# entity-framework ef-code-first many-to-many
Difference Between One-to-Many, Many-to-One and Many-to-Many?

Ok so this is probably a trivial question but I'm having trouble visualizing and understanding the differences and when to …

java hibernate orm many-to-many one-to-many
Insert/Update Many to Many Entity Framework . How do I do it?

I'm using EF4 and new to it. I have a many to many in my project and cannot seem to …

c# entity-framework many-to-many
Mapping many-to-many association table with extra column(s)

My database contains 3 tables: User and Service entities have many-to-many relationship and are joined with the SERVICE_USER table as …

hibernate jpa mapping many-to-many jointable
Rails find_or_create_by more than one attribute?

There is a handy dynamic attribute in active-record called find_or_create_by: Model.find_or_create_by_<attribute&…

ruby-on-rails activerecord model many-to-many dynamic-attributes
Django removing object from ManyToMany relationship

How would I delete an object from a Many-to-Many relationship without removing the actual object? Example: I have the models …

django many-to-many
How to implement a many-to-many relationship in PostgreSQL?

I believe the title is self-explanatory. How do you create the table structure in PostgreSQL to make a many-to-many relationship. …

sql database postgresql database-design many-to-many
Django filter many-to-many with contains

I am trying to filter a bunch of objects through a many-to-many relation. Because the trigger_roles field may contain …

python django django-models many-to-many django-orm