根据ID查询
GET /user/docs/3
GET /user/docs/3
查询到内容返回
{
"_index" : "user",
"_type" : "docs",
"_id" : "3",
"_version" : 3,
"_seq_no" : 4,
"_primary_term" : 1,
"found" : true,
"_source" : {
"name" : "李达康",
"sex" : 1,
"age" : 25,
"address" : "河北省"
}
}
{
"_index" : "user",
"_type" : "docs",
"_id" : "3",
"_version" : 3,
"_seq_no" : 4,
"_primary_term" : 1,
"found" : true,
"_source" : {
"name" : "李达康",
"sex" : 1,
"age" : 25,
"address" : "河北省"
}
}
未查到内容返回
{
"_index" : "user",
"_type" : "docs",
"_id" : "8",
"found" : false
}
{
"_index" : "user",
"_type" : "docs",
"_id" : "8",
"found" : false
}