Skip to content
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

Improve support for CQL Decimal #280

Open
cmoesel opened this issue Oct 18, 2022 · 0 comments
Open

Improve support for CQL Decimal #280

cmoesel opened this issue Oct 18, 2022 · 0 comments

Comments

@cmoesel
Copy link
Member

cmoesel commented Oct 18, 2022

The CQL Decimal type supports "decimal values in the range (-10^28 + 1)/10^8 to (10^28-1)/10^-8 with a step size of 10^-8." CQL Execution supports CQL Decimal using JavaScript Number. This implementation has a few limitations regarding the CQL specification:

  • Precision is lost at the upper and lower ends of the required range of numbers
  • Initial precision is not maintained in all cases (e.g., there is no discernible difference between 1, 1.0, and 1.00)
  • Type is not maintained for non-fractional numbers (e.g., unable to determine if 1.0 should be an integer, long, or decimal) (Engine cannot tell if whole numbers are Integers or Decimals #204)

The approach for supporting CQL Decimal should be the same (or similar) as for supporting CQL Long (#207).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
CQL Spec Alignment
Awaiting triage
Development

No branches or pull requests

1 participant