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

Feedback: Use Math Powers to describe INT ranges of values. #18656

Open
fabiog1901 opened this issue Jun 17, 2024 · 0 comments
Open

Feedback: Use Math Powers to describe INT ranges of values. #18656

fabiog1901 opened this issue Jun 17, 2024 · 0 comments

Comments

@fabiog1901
Copy link
Contributor

fabiog1901 commented Jun 17, 2024

Fabio Ghirardello (fabiog1901) commented:

Page: https://www.cockroachlabs.com/docs/v24.1/int#names-and-aliases

What is the reason for your feedback?

[ ] Missing the information I need

[ x] Too complicated

[ ] Out of date

[ ] Something is broken

[ ] Other

Additional details

It would be helpful to also describe the Range of the various INT types as math powers. For example, INT8 should be described as 2^64 / 2 + 1 to 2^64 / 2 - 1. This makes it clear how we got to those very large numbers.

Plus, it would be nice to format the numbers with 1000 notation, as in 9,223,372,036,854,775,807.

>>> 2**64 // -2 + 1
-9223372036854775807
>>> 2**64 // 2 - 1
9223372036854775807

Jira Issue: DOC-10546

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

No branches or pull requests

1 participant