阿朗戈数据:
{
"employees": [
{
"lastName": "Ansari",
"firstName": "Haseb"
},
{
"lastName": "Ansari",
"firstName": "Affan"
},
{
"lastName": "Keshav",
"firstName": "Anil"
}
],
"_id": "test/124518952473",
"_rev": "124518952473",
"_key": "124518952473"
}
索引:POST http://localhost:8529/_db/db_test/_api/index?collection=test
身体:
{
"type" : "fulltext",
"fields" : [
"lastName"
]
}
搜索:
PUT http://localhost:8529/_db/db_test/_api/simple/fulltext
身体:
{
"collection" : "test",
"attribute" : "lastName",
"query" : "Ansari"
}
我希望在我的应用程序中使用 REST API 进行全文搜索。请帮助我这里哪里出错了。例如,这是 arango 商店中的一份文件。否则,我将拥有更多文档,因此会进行全文搜索。