#Querying _creationTime range in large table
3 messages · Page 1 of 1 (latest)
3 messages · Page 1 of 1 (latest)
What are the suggested patterns for querying a large table by _creationTime?
I would like to specify a startTime and endTime but my current query still iterates over the whole table, which exceeds the limit and throws an error.
i think you can do await db.query("table").withIndex("by_creation_time", q => q.gt("_creationTime", lowerBound).lt("_creationTime", upperBound)),collect()
worked like a charm, thanks!