MongoDB是否可以通过哈希查找数据?
我正在尝试找到与此MySQL查询等效的MongoDB:
SELECT column FROM table WHERE SHA1(column) = "value"
答案 0 :(得分:0)
It doesn't seems there is any such functionality (a bit old, but couldn't find in docs.mongodb.com either), but you can include a library that contains sha1 functionality (e.g. js-sha1) in mongo shell with load function, then use it within your mongo operation.