I have posts documents and user documents how are authors of this posts. I need to get all posts which are at a given venue and for those posts the corresponding user/author documents as well.
Post:
{
"_id": "53551d9e92436f69ae04a104c2000b82",
"content": "heythere!",
"author": "a4df7fe1226fedb80f6c2dc13e000af5",
"venue": "51434246e4b0601fde0cf2eb",
"type": "post"
}
User:
{
"_id": "a4df7fe1226fedb80f6c2dc13e000af5",
"username": "sep o sep",
"type" : "user"
}
Is it possible to emit keys in the way that i will get posts to a given location along with the user documents to that posts in one couchdb query?