query = 
filteredQuery(QueryBuilders.queryString("2000/sun").defaultOperator("and"), 
null);
                
response = 
client.prepareSearch(yemme).setTypes(ymmetype).setQuery(query).setSize(20).execute().actionGet();
                        
in query string, you might want to escape the slash as it means something 
like the regex usage.

es has moved to https://discuss.elastic.co/ , you should post your question 
there.

hth

jason


On Thursday, June 4, 2015 at 3:32:54 PM UTC+8, Muddadi Hemaanusha wrote:
>
> Hi,
>
> Am using a query :
>
> GET ymme/ymmetype/_search
> {
>     "size": 20, 
>     "query": {
>        "match": {
>            "_all":
>            {
>                "query": "2000/sun ",
>                "operator": "and"
>            }
>        }
>     }
> }
>
> I would like to use the relevant query using Java API using query builders,
>
> Can anyone post the Java API code to the above query....
>

-- 
Please update your bookmarks! We have moved to https://discuss.elastic.co/
--- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/ab1431c1-0fe9-4fa2-b57b-c1ee9a414042%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to