posted 12 years ago
Hello
In my RoR application, I am using Couchrest_model to access a CouchDB database.
I have a model which represents an scientific Article.
I am going to simplify my model to explain it better. An article can have a title, a year and one or more authors.
In the couchDB database, an article can be represented like this:
(In the case the article only have an author)
OR
In the case my article have only one author, I can access author's information (name and age) like this:
Article.author.name
Article.author.age
But, how can I access the information of authors if the article have more than 1 author?