Skip to content

Show selection statistics with full double precision - #4222

Open
deepsidhu1313 wants to merge 1 commit into
sqlitebrowser:masterfrom
deepsidhu1313:fix/selection-sum-precision
Open

deepsidhu1313 wants to merge 1 commit into
sqlitebrowser:masterfrom
deepsidhu1313:fix/selection-sum-precision

Conversation

@deepsidhu1313

Copy link
Copy Markdown
Contributor

The Sum, Average, Min and Max values shown in the status bar of the Browse
Data tab were formatted with QString::arg(double), which only uses 6
significant digits. Larger values were therefore rounded, e.g. 1234567.89
was shown as 1.23457e+06. Format them with 15 significant digits instead,
which shows doubles accurately without exposing binary rounding noise.

Fixes #4033

The Sum, Average, Min and Max values shown in the status bar of the Browse
Data tab were formatted with QString::arg(double), which only uses 6
significant digits. Larger values were therefore rounded, e.g. 1234567.89
was shown as 1.23457e+06. Format them with 15 significant digits instead,
which shows doubles accurately without exposing binary rounding noise.

Fixes sqlitebrowser#4033

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Incorrect Sum reporting at the bottom of Browse Data tab status bar

2 participants