{ "$and" : [ { "status" : 3} , { "auditstatus" : 1} , { "tickettype" : { "$in" : [ 1 , 3]}} , { "$or" : [ { "departureairport" : { "$regex" : "SHA"}} , { "departureairport" : "###"}]} , { "$or" : [ { "arrivalairport" : { "$regex" : "PEK"}} , { "arrivalairport" : "###"}]} , { "$or" : [ { "workweekday" : { "$regex" : "1"}} , { "workweekday" : ""}]} , { "policynum" : { "$gt" : 3.0}} , { "$and" : [ { "flightsdatestamp" : { "$lte" : 1378569600000}} , { "flightedatestamp" : { "$gte" : 1378569600000}}]} , { "$and" : [ { "sworktimestamp" : { "$lte" : 2820000}} , { "eworktimestamp" : { "$gte" : 2820000}}]}]}
以上在mongodb默认安装下,查询需要1000ms。在oracle只需要50ms。
求帮忙。是否可以优化mongodb
|