這篇文章跟大家分析一下“ealsticsearch多種搜索方式分別是什么”。內容詳細易懂,對“ealsticsearch多種搜索方式分別是什么”感興趣的朋友可以跟著小編的思路慢慢深入來閱讀一下,希望閱讀后能夠對大家有所幫助。下面跟著小編一起深入學習“ealsticsearch多種搜索方式分別是什么”的知識吧。
我們提供的服務有:成都網站設計、網站建設、外貿網站建設、微信公眾號開發(fā)、網站優(yōu)化、網站認證、定日ssl等。為近1000家企事業(yè)單位解決了網站和推廣的問題。提供周到的售前咨詢和貼心的售后服務,是有科學管理、有技術的定日網站制作公司
PUT /ecommerce/product/1 { "name":"gaolujie yagao", "desc":"gaoxiao meibai", "price":30, "producer":"gaolujie producer", "tags":["meibai","fangzhu"] } PUT /ecommerce/product/2 { "name":"jiajieshi yagao", "desc":"gaoxiao fangzhu", "price":25, "producer":"jiajieshi producer", "tags":["fangzhu"] } PUT /ecommerce/product/3 { "name":"zhonghua yagao", "desc":"caoben zhiwu", "price":40, "producer":"zhonghua producer", "tags":["qingxin"] }
GET /ecommerce/product/1
PUT /ecommerce/product/1 { "name":"jiaqianban gaolujie yagao", "desc":"gaoxiao meibai", "price":30, "producer":"gaolujie producer", "tags":["meibai","fangzhu"] }
PUT /ecommerce/product/1 { "name":"jiaqianban gaolujie yagao" }
POST /ecommerce/product/1/_update { "doc":{ "name":"gaolujie yagao" } }
DELETE /ecommerce/product/1
GET /ecommerce/product/_search GET /ecommerce/product/_search?q=name:yagao&sort=price:desc
GET /ecommerce/product/_search { "query": { "match_all": {} } }
GET /ecommerce/product/_search { "query": { "match": { "name":"yagao" } }, "sort": [ { "price": { "order": "desc" } } ] }
GET /ecommerce/product/_search { "query": { "match_all": {} }, "from": 0, "size":1 }
GET /ecommerce/product/_search { "query": { "match_all": {} } , "_source": ["name","price"] }
GET /ecommerce/product/_search { "query": { "bool": { "must": [ {"match": { "name": "yagao" }}] , "filter": { "range": { "price": { "gt": 25, "lt": 50 } } } } } }
PUT /ecommerce/product/5 { "name":"special yagao", "desc":"special meibai", "price":50, "producer":"special yagao producer", "tags":["meibai"] } GET /ecommerce/product/_search { "query": { "match": { "producer": "yagao producer" } } }
GET /ecommerce/product/_search { "query": { "match_phrase": { "producer": "yagao producer" } } }
GET /ecommerce/product/_search { "query": { "match": { "producer": "producer" } } , "highlight": { "fields": { "producer":{} } } }
關于ealsticsearch多種搜索方式分別是什么就分享到這里啦,希望上述內容能夠讓大家有所提升。如果想要學習更多知識,請大家多多留意小編的更新。謝謝大家關注一下創(chuàng)新互聯網站!