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

Runtime: Cast Clickhouse DECIMALs to floats in metrics APIs #5512

Merged

Conversation

begelundmuller
Copy link
Contributor

@begelundmuller begelundmuller commented Aug 23, 2024

In Go, ClickHouse returns DECIMAL types as strings instead of bigs when not explicitly scanned into a different data type. This PR casts those strings to float64s before returning them in the metrics APIs.

Note that this is a bad practice, but something we have done historically for DuckDB numbers because the frontend can't yet handle non-float numbers.

@begelundmuller begelundmuller merged commit 8174508 into main Aug 23, 2024
6 checks passed
@begelundmuller begelundmuller deleted the begelundmuller/cast-clickhouse-decimals-to-float branch August 23, 2024 12:04
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.

2 participants