mysql 索引 KEY与INDEX的区别: KEY is something on the logical level, describes your table and database design.INDEX is something on the physical level, helps improve access time for table operations. KEY是关系模型理论中的一部份,比如有主键(Primary Key),外键(Foreign Key)等,用于数据完
用$where可以执行任意的js作为查询的一部分. db.foo.find({"$where" : function(){ for(var current in this){ for(var other in this){ if(current != other && this[current] == this[other]){ return true;