You don't have any document which have both values. Try with laptopModelId:"Vostro" sellAdState:"Karnataka"
-- David ;-) Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs Le 1 sept. 2014 à 07:01, ravi kumar <[email protected]> a écrit : Here is the sample data "hits" : [ { "_index" : "myIndex", "_type" : "sellItemsIndices", "_id" : "4ks8w", "_score" : 1.0, "_source":{"sellAdState":"Karnataka"} } { "_index" : "myIndex", "_type" : "laptopIndices", "_id" : "4ks8w", "_score" : 1.0, "_source":{"laptopModelId":"Vostro"} } now i want to execute below query laptopModelId:"Vostro" AND sellAdState:"Karnataka" Here is the java code that returns nothing SearchResponse response = client.prepareSearch("myIndex") .setTypes("laptopIndices","sellItemsIndices") .setQuery(QueryBuilders.queryString("laptopModelId:\"Vostro\" AND sellAdState:\"Karnataka\"")) .execute() .actionGet(); One more thing is there some limitation or performance issue if I add large number of field in _source -- 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 [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/fc59d51c-5424-483c-9992-5a003614f815%40googlegroups.com. For more options, visit https://groups.google.com/d/optout. -- 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 [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/BE79C210-D6D3-4D7E-9991-C459AE3E47F2%40pilato.fr. For more options, visit https://groups.google.com/d/optout.
