# Scoring from multiple queries

**URL:** <https://discuss.elastic.co/t/scoring-from-multiple-queries/11682>\
**Category:** Elasticsearch\
**Created:** [April 24, 2013, 1:18pm UTC](https://discuss.elastic.co/t/scoring-from-multiple-queries/11682 "2013-04-24T13:18:14Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![plaflamme](https://avatars.discourse-cdn.com/v4/letter/p/a88e57/32.png) [@plaflamme](https://discuss.elastic.co/u/plaflamme)\
**Post date:** [April 24, 2013, 1:18pm UTC](https://discuss.elastic.co/t/scoring-from-multiple-queries/11682/1 "2013-04-24T13:18:14Z")

</div>

Hi,

We have an index with 2 types, one being the child of another. The child  
document contains derived data from the parent document, so there's only  
one child per parent. The reason why we do this is because the data in the  
child can change even when the parent doesn't actually change (ie: the  
child document data is derived from multiple documents in the parent type).  
We could put the data in the parent document, but that requires updating  
them which we'd like to avoid.

We'd like to score parents based some queries to them, but more  
importantly, using values in its child document in a custom\_score query.  
Here's what I'd like to achieve[1].

Thanks,  
Philippe  
[1] [https://gist.github.com/plaflamme/3ec53a6ae6a5f6896066](https://gist.github.com/plaflamme/3ec53a6ae6a5f6896066)

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 2:39am UTC](https://discuss.elastic.co/t/scoring-from-multiple-queries/11682/2 "2017-07-06T02:39:46Z")

</div>


