Search JAVA search API not working

Are you just searching in your code or indexing as well?
Could it be caused because you did not refresh before searching?

--
David :wink:
Twitter : @dadoonet / @elasticsearchfr / @scrutmydocs

Le 21 mars 2014 à 22:13, Mohit Anchlia mohitanchlia@gmail.com a écrit :

The below code doesn't seem to match the document for some reason. Same query when run directly using REST API works. Am I doing something wrong in the code?

queryString="fields.field1:value1";

		searchResponse = client.prepareSearch()
				.setQuery(QueryBuilders.queryString(queryString)).execute()
				.actionGet();

Doc that I expect to match
'{
"namespace": "ns1",
"id": "3",
"fastId": "f1",
"version": 1393443298027,
"lang": "en",
"opType": "create",
"fields": {
"field2": "value2",
"field1": "value1"
},
"arrayFields": {}
}'

--
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.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAOT3TWoSGTpNQpHBUUNpa0qQr0X8rm7pZXoqxYqcb-349xkrmA%40mail.gmail.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 elasticsearch+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/0772CCDA-1515-4B40-8808-FA701E358327%40pilato.fr.
For more options, visit https://groups.google.com/d/optout.