Docs Menu
Docs Home
/ / /
Node.js
/

Time Series

On this page

  • Overview
  • Create a Time Series Collection
  • Query a Time Series Collection

In this guide, you can learn about time series collections in the MongoDB Node.js driver.

We recommend that you create a time series collection using the MongoDB Shell. Learn more about how to install and run the MongoDB Shell in the MongoDB Shell documentation. For detailed instructions on creating a time series collection using the MongoDB Shell, see our MongoDB Manual entry on time series collections.

Since you query a time series collection in the same way you query other collection types in MongoDB, the Node.js driver has no features specifically for querying time series data.

For more information on querying data in the MongoDB Node.js driver, see the following resources:

  • Guide On Read Operations

  • Guide On Aggregation

Note

Window Functions

MongoDB version 5.0 introduces window functions into the MongoDB aggregation pipeline. You can use window functions to perform operations on a contiguous span of time series data. For more information, see the reference documentation for the $setWindowFields aggregation stage.

Back

GridFS