—- 查看所有索引172.16.14.174
curl -XGET 'http://192.168.21.16:9200/_cat/indices?v&pretty'
—- 表结构
curl -XGET 'http://192.168.21.16:9200/selection_badreview_monitor_log_index/selection_badreview_monitor_log_index/_mapping?pretty'
-- 新增列
curl -H "Content-Type: application/json" -XPOST 'http://172.16.14.174:9200/selection_product_basic_latest_v1/_mapping/selection_product_basic_latest_v1' -d '{"properties":{"combine_column":{"type": "keyword"}}}'
-- 删除
curl -XDELETE 'http://172.16.14.174:9200/selection_product_basic_latest_v1'
-- 查询
curl -H "Content-Type: application/json" -XPOST 'http://192.168.21.16:9200/selection_badreview_monitor_log_index/selection_badreview_monitor_log_index/_search?pretty' -d '
{
"query":{
"range":{
"reviewDate":{
"gte": "2018-10-12",
"lte": "2018-10-13"
} }}
}'
-- 新增
curl -H "Content-Type: application/json" -XPOST 'http://172.16.31.74:9200/selection_product_basic/selection_product_basic' -d'
{
"marketplace": "amazon",
"day": "2018-08-24",
"product_current_asin": "liuwei",
"product_parent_asin": "B01JHTFTC8",
"product_current_category": "Socks",
"product_parent_categories": [
"Clothing, Shoes & Jewelry",
"Baby",
"Baby Boys",
"Accessories"
],
"product_categories": [
"Clothing, Shoes & Jewelry",
"Baby",
"Baby Boys",
"Accessories",
"Socks"
],
"timestamp": "2018-08-27 19:48:30"
}'
-- 查询表结构
curl -XGET 'http://172.16.14.174:9200/selection_product_basic_latest_v1/selection_product_basic_latest_v1/_mapping?pretty'
--
es的crud操作
最后编辑于 :
©著作权归作者所有,转载或内容合作请联系作者
- 文/潘晓璐 我一进店门,熙熙楼的掌柜王于贵愁眉苦脸地迎上来,“玉大人,你说我怎么就摊上这事。” “怎么了?”我有些...
- 文/花漫 我一把揭开白布。 她就那样静静地躺着,像睡着了一般。 火红的嫁衣衬着肌肤如雪。 梳的纹丝不乱的头发上,一...
- 文/苍兰香墨 我猛地睁开眼,长吁一口气:“原来是场噩梦啊……” “哼!你这毒妇竟也来了?” 一声冷哼从身侧响起,我...