用 $sort + $group($first) + hint 替代 $max,配合复合索引
{mId:1,status:1,reviewAt:-1} 减少 key examined。
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
用 $sort + $group($first) + hint 替代 $max,配合复合索引
{mId:1,status:1,reviewAt:-1} 减少 key examined。
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>