Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
たとえば、過去 6 か月間を、毎日最も早いインスタンスでクエリする必要があります (最終日は各時間の最も早いインスタンスで、最後の日は分で)。私はMongoDBを使用して、ネストされた構造を持つことを考えていました
year:{ month:{ day: { hour: { minute: [array of seconds]
しかし、最初のインスタンスを取得するには、コストのかかる配列をソートする必要があります。もっと簡単な方法はありますか?