当前位置:网站首页>ES关于文档的基本操作
ES关于文档的基本操作
2022-08-10 09:48:00 【小染r】
基本操作
1.添加数据:
PUT /ran/user/3
{
“name”:“李四”,
“age”:33,
“desc”:“厉害”,
“tags”:[“啊这游”,“帅”,“关东”]
}

2.查询,获取数据
GET ran/user/1

3、更新数据PUT (不推荐)
put 如果不传递值就会被覆盖
version:代表这条数据被改动的次数
result:代表当前这条数据的操作状态
4、POST 提交请求 … -> update (更新推荐使用这种方式,不需要填写全部信息,自由度更高)


简单的搜索
GET ran/user/1
简单的条件查询 可以根据默认的映射规则,产生基本的查询!
GET /ran/user/_search?q=name:染
旧版: GET /索引/类型/_search?q=name:染
新版:GET /索引/_search?q=name:染
score: 未来如果存在多条数据查询出来的结果!
匹配度越高则分值越高
复杂操作搜索 select (排序,分页,高亮,模糊查询,精准查询)

边栏推荐
猜你喜欢

因子分析(SPSS)

【元宇宙欧米说】看UCOUCO如何将行为艺术融入元宇宙

多元线性回归分析(Stata)

英伟达游戏显卡营收暴跌/ 谷歌数据中心爆炸致3人受伤/ iPhone电量百分比回归…今日更多新鲜事在此...

The Generation of Matlab Symbolic Functions and the Calculation of Its Function Values

Tencent releases the second-generation version of the quadruped robot Max, which completes jumps and somersaults on the plum blossom pile
原型和原型链

BUUCTF【pwn】解题记录(4-6页持续更新中)

Flink部署 完整使用 (第三章)

Which is the strongest workflow engine for "Technology Selection"?Chief Architecture Helps You Pick
随机推荐
CAD转WPF: 关于CAD图纸文件转换为WPF矢量代码文件(xaml文件)的技巧
The Generation of Matlab Symbolic Functions and the Calculation of Its Function Values
高通 msm8953 LCD 休眠/唤醒 流程
【API 管理】什么是 API 管理,为什么它很重要?
jq封装树形下拉选择框组件
FPGA时钟篇(一) 7系列的时钟结构
Lasso regression (Stata)
Tencent releases the second-generation version of the quadruped robot Max, which completes jumps and somersaults on the plum blossom pile
「应用架构」TOGAF建模:企业可管理性图
VBA: 采用Combox控件实现二级下拉菜单功能
PostgreSQL 2022 发展现状:13 个非 psql 工具
Guo Jingjing's personal chess teaching, the good guy is a robot
BUUCTF problem solving PWN 】 【 record (4-6 pages continuously updated)
如何理解BIO、NIO、AIO的区别
"Guangzhou highway engineering measures for the supervision and administration of production safety, and revised from six aspects
武功修炼:招式
LCD DRM驱动框架分析一
【软考 系统架构设计师】系统可靠性分析与设计① 系统可靠性分析
「应用架构」TOGAF建模:应用程序迁移图
13 【script setup 总结】