Azure-cosmos-dotnet-v3: EnableCrossPartitionQuery query property missing in 3.x SDK

Created on 22 Aug 2019  路  2Comments  路  Source: Azure/azure-cosmos-dotnet-v3

Describe the bug
I'm migrating our project to use Microsoft.Azure.Cosmos 3.1.1 instead of Microsoft.Azure.DocumentDB version 1.10. Everything is working fine except I noticed that I can't specify the EnableCrossPartitionQuery parameter. We used to set this in FeedOptions that was passed to CreateDocumentQuery. The other properties (like MaxItemCount) are in QueryRequestOptions that we now pass to GetItemQueryIterator but I don't see EnableCrossPartitionQuery.

Is this automatically set based on if we pass in a partition key? Thanks!

To Reproduce

Expected behavior

Actual behavior

Environment summary
SDK Version: 3.1.1
OS Version (e.g. Windows, Linux, MacOSX) Windows

Most helpful comment

Hi @dan-silver,

The v3 SDK sets the EnableCrossPartitionQuery automatically based on the query and QueryRequestOptions.PartitionKey value. There is no need to set it in v3.

All 2 comments

Hi @dan-silver,

The v3 SDK sets the EnableCrossPartitionQuery automatically based on the query and QueryRequestOptions.PartitionKey value. There is no need to set it in v3.

Thank you for the quick answer @j82w . Closing issue

Was this page helpful?
0 / 5 - 0 ratings

Related issues

kirankumarkolli picture kirankumarkolli  路  7Comments

thomaslevesque picture thomaslevesque  路  7Comments

johngallardo picture johngallardo  路  4Comments

Liversage picture Liversage  路  7Comments

wahyuen picture wahyuen  路  4Comments