Content-Length: 219638 | pFad | http://github.com/react-querybuilder/react-querybuilder/issues/901

6A Loss of precision when parsing bigint values in SQL query · Issue #901 · react-querybuilder/react-querybuilder · GitHub
Skip to content

Loss of precision when parsing bigint values in SQL query #901

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

Open
kosolapus opened this issue Jun 10, 2025 · 1 comment
Open

Loss of precision when parsing bigint values in SQL query #901

kosolapus opened this issue Jun 10, 2025 · 1 comment

Comments

@kosolapus
Copy link

React Query Builder version

v8.4.1

Platform

Chrome on MacOS 15.4

Description

When trying to parse an SQL query containing a bigint literal, the library appears to lose precision for large numeric values.

For example, parsing the following query:
SELECT *
FROM my_table
WHERE id > 1000000000000000644

results in the value 1000000000000000600 instead of the expected 1000000000000000644.

This causes issues when working with bigint values that require exact precision.

Reproduction

This behavior can be reproduced directly on the demo page.
Simply input the following query and observe the parsed output:

WHERE age > 100000000000000045

Expected behavior

The parsed query should retain the exact numeric value without any loss of precision.

Additional information

If this behavior is intentional or there is a recommended workaround for handling bigint values accurately, please let me know.

@jakeboone02
Copy link
Member

No workaround for now, but seems like a relatively simple fix. I'll try to have a patch out soon.

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

2 participants








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/react-querybuilder/react-querybuilder/issues/901

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy