Inner queries in Elastic search

hi,

Is there any way where we can do inner queries in Elastic Search.
Means I want to query on a doc_type and use the result to this query as input to another query.