【发布时间】:2015-08-29 17:25:49
【问题描述】:
Given that new Documents and querys:
{
"_id" : ObjectId("55803fd1cc0c9aa090e608be"),
"song_name" : "Mickey is good",
"time" : "3.56",
"artist" : "Mickey"
}
{
"_id" : ObjectId("55803fd1cc0c9aa090e608bf"),
"song_name" : "Love is nothing",
"time" : "5.56",
"artist" : "Jimmy"
}
我需要找出哪些歌曲的标题与艺术家姓名相同。 我努力了: db.myCollection.find( { $where: "this.artist == /this.song_name/" } );
但没有成功。请帮忙`
【问题讨论】:
-
到目前为止你做了什么,请分享...
-
我已经用我目前所做的修改了我的查询..
标签: regex mongodb mongodb-query