Top "One-to-one" questions

Refers to the quantity of an entity as a relationship to another entity.

Unable to determine the principal end of an association between the types

Here is the situation. There are two type of ElectricConsumer ie CommercialConsumers & DomesticConsumers(Quaters) and one Quater is allocated …

c# entity-framework ef-code-first one-to-one ado.net-entity-data-model
Foreign key field null in @OneToOne mapping with Hibernate/JPA

I have two entities, Document and BodyElement, and trying to persist them with Hibernate 4.2. mtdt_t populates correctly, but the …

hibernate one-to-one
When to use one-to-one relationships in Django models

I've read a few places (see the second answer) that one-to-one relationships in Django models should almost always only be …

python django models one-to-one
JPA: one-to-one + self referential + bidirectional

I have an entity called 'Instructions'. Sometimes each Instructions has to keep track Instructions before and after it. For Example …

java jpa one-to-one bidirectional self-reference
SQLAlchemy one-to-one relation, primary as foreign key

I am mapping classes to existed MySQL tables generated by Drupal. I need to relate to tables(one-to-one), but I've …

python sqlalchemy one-to-one
How to delete Child or Parent objects from Relationship?

I did a small application with more relationships. Now I want to delete details of my table how can I …

java hibernate jpa one-to-one many-to-one
SQLAlchemy query filter on child attribute

My model consists of a Parent and Child with a one-to-one relationship: class Parent(Base): __tablename__ = 'parent' id = Column(Integer, …

python orm sqlalchemy one-to-one
Django OneToOneField with possible blank field

Working with Django 1.11 and a postgreSQL Database (just switched from sqlite and didn't have this problem before) So I have 3 …

python django postgresql one-to-one
JPA @OneToOne throws Error when mapped to an abstract @Entity with subclasses

I have a problem when an Entity is mapped to another Entity which has a direct implementation on its subclasses. …

java hibernate jpa entitymanager one-to-one