# Looking up values from a diiferent index to the one being searched

**URL:** <https://discuss.elastic.co/t/looking-up-values-from-a-diiferent-index-to-the-one-being-searched/362111>\
**Category:** Elasticsearch\
**Created:** [June 26, 2024, 5:33pm UTC](https://discuss.elastic.co/t/looking-up-values-from-a-diiferent-index-to-the-one-being-searched/362111 "2024-06-26T17:33:53Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![xef](https://avatars.discourse-cdn.com/v4/letter/x/898d66/32.png) [@xef](https://discuss.elastic.co/u/xef)\
**Post date:** [June 26, 2024, 5:33pm UTC](https://discuss.elastic.co/t/looking-up-values-from-a-diiferent-index-to-the-one-being-searched/362111/1 "2024-06-26T17:33:53Z")

</div>

Let's say we have an index for Jobs to be carried out called "jobs". In this index there is a field called localityId which is a string that represnets where the job location is. This string is defined in another index called **localities** which when looked up gives us the polygon information.

What we would like to do is something like this: Include the Job document in the results if the Locality represented in the Jobs index(by its LocalityId) by looking it up in the localities index (where the polygon is defined for the locality) intersects the circle:

` filters.Add(fq => fq.GeoShape(g => g.Shape(b => b.Circle(pro.Location, pro.OperationRadius.ToString())).Relation(GeoShapeRelation.Intersects).IndexedShape(f => f.Id(LocationId).Index("localities").Path("locationShape"))));`

But the problem is that we have to provide a single Id (localityId) as opposed to the localityId of each record being evaluated in the jobs index.

Is there any way we can achieve this? Thanks  
We would greatly appreciate if the Elastic team could tell us if this is at all possible even if you do not wish to provide the answer so that we can think of some other way.
