Is it possible to define a one-to-one association in Ektorp? In the Ektorp documentation I only found how to embed a list of objects into an object referenced by foreign key. I want to produce a document like:
{
name: "John",
surname: "Smith",
address: {
street: "Abc Street",
zip: "12345",
city: "My City"
}
}
Thanks
Embedding a complete document like this is very friendly. One straightforward way to do this is by defining a
Contactclass that has anAddressclass.When written to the database, it will produce a document that looks like: