Couchbase: What is the most efficient way to find the parent of a nested document? -
assume:
{ "id":"parent1", "name":"parent-name", "children":[ { "id":"child1", "name":"child1-name" }, { "id":"child2", "name":"child2-name" } ] }
knowing child1 id, formulate query find out id of parent.
i have seen satisfies condition looking more ways efficiently figure out parent since creating query satisfies clause iterate through children (linear).
Comments
Post a Comment