# Search across types in query body

**URL:** <https://discuss.elastic.co/t/search-across-types-in-query-body/18900>\
**Category:** Elasticsearch\
**Created:** [July 25, 2014, 10:21am UTC](https://discuss.elastic.co/t/search-across-types-in-query-body/18900 "2014-07-25T10:21:55Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Manuel\_Vacelet\_2](https://avatars.discourse-cdn.com/v4/letter/m/8491ac/32.png) [@Manuel\_Vacelet\_2](https://discuss.elastic.co/u/Manuel_Vacelet_2)\
**Post date:** [July 25, 2014, 10:21am UTC](https://discuss.elastic.co/t/search-across-types-in-query-body/18900/1 "2014-07-25T10:21:55Z")

</div>

Hi there,

I'm playing with search across types with queries of form:  
curl -XPOST 'localhost:9200/trk/110,112/\_search ...

And I'm wondering if there is a way to specify the types I want to search  
on in the query body.  
Like:  
curl -XPOST 'localhost:9200/trk/\_search -d '{  
...  
}'

It seems that the feature exists for cross-index searches[1] but I fail to  
find the cross-type equivalent.

[1]  
[http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dsl-indices-query.html](http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dsl-indices-query.html)

Manuel

--  
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).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAP66XbHe-PQS1cy3MmPcgTMMLj%2BPuZRK5MtKbb7ytZj3g\_oGUw%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAP66XbHe-PQS1cy3MmPcgTMMLj%2BPuZRK5MtKbb7ytZj3g_oGUw%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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, 1:13am UTC](https://discuss.elastic.co/t/search-across-types-in-query-body/18900/2 "2017-07-06T01:13:07Z")

</div>


