{
"_id" : ObjectId("50ff7c427995fe330400000a"),
"group_name" : "College",
"owner" : "50f69176904e1d66affec20d",
"users" : [
{
"id" : "50f69176904e1d66affec20d"
},
{
"id" : "50f69176904e1d66affec20d"
},
{
"id" : "50f69176904e1d66affec20d"
}
]
}
{
"_id" : ObjectId("50ff88e17995fe3204000002"),
"group_name" : "PHP",
"owner" : "50f69176904e1d66affec20d",
"users" : [
{
"id" : "50f69176904e1d66affec20d"
}
],
"visibility" : "public"
}
{
"_id" : ObjectId("50ff86e17995fe3204000001"),
"group_name" : "Lithium",
"owner" : "50f69176904e1d66affec20d",
"users" : [
{
"id" : "50f69176904e1d66affec20d"
}
],
"visibility" : "public"
}
{
"_id" : ObjectId("50ff98397995fe3204000003"),
"group_name" : "MongoDB",
"owner" : "50f69176904e1d66affec20d",
"users" : [
{
"id" : "50f69176904e1d66affec20d"
}
],
"visibility" : "public"
}
在上面的集合中,我想使用通配符来获取 group_name。通配符应该是双向的,即;如果我在搜索字符串中输入“h”,那么我应该能够同时获得“Lithium”和“PHP”。请帮助!