arangosh> db.emails.ensureFulltextIndex("content");
{
"fields" : [
"content"
],
"id" : "emails/16475",
"isNewlyCreated" : true,
"minLength" : 2,
"sparse" : true,
"type" : "fulltext",
"unique" : false,
"code" : 201
}
arangosh> db.emails.save({ content:
........> "Hello Alice, how are you doing? Regards, Bob"});
{
"_id" : "emails/16478",
"_key" : "16478",
"_rev" : "_VvTS__O---"
}
arangosh> db.emails.save({ content:
........> "Hello Charlie, do Alice and Bob know about it?"});
{
"_id" : "emails/16482",
"_key" : "16482",
"_rev" : "_VvTS__S---"
}
arangosh> db.emails.save({ content: "I think they don't know. Regards, Eve" });
{
"_id" : "emails/16485",
"_key" : "16485",
"_rev" : "_VvTS__S--_"
}
arangosh> db.emails.fulltext("content", "charlie,|eve").toArray();
[
{
"_key" : "16482",
"_id" : "emails/16482",
"_rev" : "_VvTS__S---",
"content" : "Hello Charlie, do Alice and Bob know about it?"
},
{
"_key" : "16485",
"_id" : "emails/16485",
"_rev" : "_VvTS__S--_",
"content" : "I think they don't know. Regards, Eve"
}
]