-
Notifications
You must be signed in to change notification settings - Fork 501
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Heiarchical Partition Keys: Fixes bug for ReadMany where None
Partition does not return results
#4977
base: master
Are you sure you want to change the base?
Heiarchical Partition Keys: Fixes bug for ReadMany where None
Partition does not return results
#4977
Changes from 4 commits
1186562
2f2fd2a
a54335d
7108f98
ab1c291
0f4d681
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -304,6 +304,15 @@ private QueryDefinition CreateReadManyQueryDefinitionForOther(List<(string, Part | |
} | ||
for (int j = 0; j < this.partitionKeySelectors.Count; j++) | ||
{ | ||
if (pkValues[j] == Undefined.Value) | ||
{ | ||
queryStringBuilder.Append(" AND "); | ||
queryStringBuilder.Append("IS_DEFINED(c"); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Clarification: Create will not work if any of the partition-keys are not defined right? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can this clause it-self be excluded? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Create will be able to work with |
||
queryStringBuilder.Append(this.partitionKeySelectors[j]); | ||
queryStringBuilder.Append(") = false"); | ||
continue; | ||
} | ||
|
||
queryStringBuilder.Append(" AND "); | ||
queryStringBuilder.Append("c"); | ||
queryStringBuilder.Append(this.partitionKeySelectors[j]); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In-general ReadMany is for many point operation reads => each partition-key should be complete/full.
Hierarchical partitions: ReadMany as name might get mis-mapped for HierarchicalParittioning, isn't the ideal solution to use regular query instead?