# Multiple locations withing a document for geo queries

**URL:** <https://discuss.elastic.co/t/multiple-locations-withing-a-document-for-geo-queries/12783>\
**Category:** Elasticsearch\
**Created:** [July 14, 2013, 2:47am UTC](https://discuss.elastic.co/t/multiple-locations-withing-a-document-for-geo-queries/12783 "2013-07-14T02:47:59Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Akash\_Ashok](https://avatars.discourse-cdn.com/v4/letter/a/898d66/32.png) [@Akash\_Ashok](https://discuss.elastic.co/u/Akash_Ashok)\
**Post date:** [July 14, 2013, 2:47am UTC](https://discuss.elastic.co/t/multiple-locations-withing-a-document-for-geo-queries/12783/1 "2013-07-14T02:47:59Z")

</div>

Hi All,  
I have a question regarding how to use elastic search for my purpose  
I am building a carpooling app

1. So when some1 wants to post a ride shall index all lat long in the path  
or approximatly all important lat longs.
2. So now i have rides document with a list of location points
3. Will i be able to a geo distance search on th elist of lat longs to  
match any of the latlongs find the closest one it matches to ?

Cheers,  
Akash A

--  
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:** ![spinscale](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/spinscale/32/25011_2.png) [@spinscale](https://discuss.elastic.co/u/spinscale)\
**Post date:** [July 15, 2013, 6:19am UTC](https://discuss.elastic.co/t/multiple-locations-withing-a-document-for-geo-queries/12783/2 "2013-07-15T06:19:36Z")

</div>

Hey,

I do not think that 'indexing all the lat/longs" of a route is a good idea,  
if your system should scale (and have a working search). Having the  
important ones such as start/stop/via points should be sufficient.

Regarding point 3, please look at

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

there is also the new geo hash cell filter in 0.90, geoshape  
queries/filters a geo bounding box filter. Summed up: Plenty of stuff to  
play around with and see if it works for you.

--Alex

On Sun, Jul 14, 2013 at 4:47 AM, Akash Ashok [thehellmaker@gmail.com](mailto:thehellmaker@gmail.com) wrote:

> Hi All,  
> I have a question regarding how to use Elasticsearch for my purpose  
> I am building a carpooling app
> 
> 1. So when some1 wants to post a ride shall index all lat long in the  
> path or approximatly all important lat longs.
> 2. So now i have rides document with a list of location points
> 3. Will i be able to a geo distance search on th elist of lat longs to  
> match any of the latlongs find the closest one it matches to ?
> 
> Cheers,  
> Akash A
> 
> --  
> 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).

--  
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:26am UTC](https://discuss.elastic.co/t/multiple-locations-withing-a-document-for-geo-queries/12783/3 "2017-07-06T02:26:31Z")

</div>


