Skip to content

Conversation

@cincuranet
Copy link
Contributor

@cincuranet cincuranet commented Nov 18, 2025

Backport of #37197.

Description

Incorrect logic was present for bucketization (padding) computation when number of values is between 2070 and 2100 where we want to minimize padding near the limit for SQL Server.

Customer impact

Exception thrown when number of values is between 2070 and 2100.

How found

Customer reported on 10.0.

Regression

Yes.

Testing

Tests added.

Risk

Low. This is a targeted fix. Quirk added.

@cincuranet cincuranet changed the title [release/10.0.1] Fix bucketization for number of parameters between 2070 and 2100. [release/10.0.1] Fix bucketization for number of values between 2070 and 2100. Nov 18, 2025
@cincuranet cincuranet changed the title [release/10.0.1] Fix bucketization for number of values between 2070 and 2100. [release/10.0.1] Fix bucketization for number of values between 2070 and 2100 for SQL Server. Nov 18, 2025
@cincuranet cincuranet marked this pull request as ready for review November 18, 2025 12:54
@cincuranet cincuranet requested a review from a team as a code owner November 18, 2025 12:54
@cincuranet cincuranet requested review from artl93 and roji November 18, 2025 12:54
@SamMonoRT SamMonoRT added this to the 10.0.1 milestone Nov 18, 2025
Copy link
Member

@roji roji left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As there aren't multiple actual codepaths here, a single test should be enough to cover this, but LGTM regardless.

@cincuranet
Copy link
Contributor Author

cc @artl93

@cincuranet
Copy link
Contributor Author

Approved via email.

@cincuranet cincuranet merged commit a6217e3 into dotnet:release/10.0 Nov 18, 2025
7 checks passed
@cincuranet cincuranet deleted the fix-2070-release-10 branch November 18, 2025 18:25
@ViktorHofer ViktorHofer changed the title [release/10.0.1] Fix bucketization for number of values between 2070 and 2100 for SQL Server. [release/10.0] Fix bucketization for number of values between 2070 and 2100 for SQL Server. Nov 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

EF Core 10 throws System.DivideByZeroException if number of parameters are between 2070 and 2100

4 participants