5 ms·
Cosmosdb still doesn’t support skip and take. And aggregate queries are incredibly inefficient. We’ve had to move a heap of data from cosdb to sql server, our r
by shearnie 7y ago
Cosmosdb still doesn’t support skip and take.
And aggregate queries are incredibly inefficient.
We’ve had to move a heap of data from cosdb to sql server, our reports ran from 3 hours, to now 5 minutes after moving to SQL.
- cheschire 7y agoI may be taking your post at face value, but I suggest if you are using skip, i.e. LINQ Skip(), that you stop. SQL's performance using OFFSET is pretty terrible when you start getting into the 10's of thousands of records. Instead, use seek instead. Here's some random google result that talks about the concept. There are plenty out there though. https://blog.jooq.org/2013/10/26/faster-sql-paging-with-jooq-using-the-seek-method/ https://blog.jooq.org/2013/10/26/faster-sql-paging-with-jooq...
- manigandham 7y agoHow were you aggregating data? ComosDB is a document-store and not a relational database and wasn't designed for large-scale aggregations. There are ways to use the Javascript UDFs to aggregate data within a partition but across-partitions is not a good fit for this architecture.
- sthota 7y agoHi, I am from Azure Cosmos DB engineering team. We continue to optimize our indexing layout – there are several key improvements being rolled out. Please share the details of your expensive query (askcosmosdb@microsoft.com) to help us investigate. OFFSET/LIMIT (Skip/Take) is currently in private preview. It will be broadly available by 5/15/2019.