尝试使用 MongoDB PHP 驱动程序将 '$or' 与日期范围组合时出现以下错误:
Fatal error: Uncaught exception 'MongoCursorException' with message '$and/$or/$nor must be a nonempty array' in [FILE.php]:67
这是我的查询条件:
Array
(
[$and] => Array
(
[0] => Array
(
[fileowner] => 51f17509d5cddc2d52000000
)
[1] => Array
(
[$or] => Array
(
[created] => Array
(
[$gt] => 1367812800
[$lt] => 1367899200
)
[accessed] => Array
(
[$gt] => 1367812800
[$lt] => 1367899200
)
)
)
)
)
我不应该以这种方式组合这些条件吗?