Top "One-to-one" questions

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

Why use a 1-to-1 relationship in database design?

I am having a hard time trying to figure out when to use a 1-to-1 relationship in db design or …

database database-design database-schema one-to-one
How to map OneToOne relationship between POJOs using @JsonManagedReference and @JsonBackReference

I have read http://vard-lokkur.blogspot.com/2010/10/json-jackson-to-rescue.html http://vard-lokkur.blogspot.com/2010/10/json-jackson-serialization-narrowed.html http://www.cowtowncoder.com/blog/…

json jackson one-to-one
JPA / Hibernate unidirectional one-to-one mapping with shared primary key

I'm having a very hard time trying to get a unidirectional one-to-one relationship to work with JPA (Provider: Hibernate). In …

java hibernate jpa jakarta-ee one-to-one
Hibernate ManyToOne vs OneToOne

I can't see any difference in the schema of a Many-To-One relationship vs a OneToOne relationship: @Entity public class Order { @…

hibernate one-to-one many-to-one
Fluent NHibernate & one-to-one

For a (very) long time I've been looking for an example on how to correctly implement a one-to-one mapping with …

fluent-nhibernate one-to-one
OneToOne relationship for a non primary key column

I'm having a problem when I query an entity who has a OneToOne relationship with another one. This is the …

java jakarta-ee jpa one-to-one joincolumn
Check if a OneToOne relation exists in Django

Now I'm using django 1.6 I have two models relates with a OneToOneField. class A(models.Model): pass class B(models.…

python django model one-to-one
ModelForm with OneToOneField in Django

I have two models in Django that are related with a OneToOneField (PrinterProfile and PrinterAdress). I am trying to do …

django one-to-one django-forms
ORM: OneToOne mapping on Non Primary-Key Join column - Book and Inventory mapped by ISBN

I have a Book model and Inventory model mapped by ISBN number, but ISBN is not the primary key in …

java hibernate orm activerecord one-to-one
Create one to one relationship by using entity framework database first

In EF Code First, we can create one-to-one relationship by coding like this: public class User { public int UserID {get;…

entity-framework ef-code-first one-to-one ef-database-first