-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Cannot read floating point infinity values from JDBC #62601
Comments
Hello, I am Blathers. I am here to help you get the issue triaged. Hoot - a bug! Though bugs are the bane of my existence, rest assured the wretched thing will get the best of care here. I was unable to automatically find someone to ping. If we have not gotten back to your issue within a few business days, you can try the following:
🦉 Hoot! I am a Blathers, a bot for CockroachDB. My owner is otan. |
hi @lukaseder! thanks for this report. we'll take a closer look soon. |
We can probably make this change for 21.2 -- looks like Go is able to parse both |
I would like to take this issue. |
@neel229 Thanks! Here are a few steps:
Only remove the comments for Inf and -Inf.
After you do all this, I'm guessing some of our other tests will fail. But start with these and we'll address the other ones later. |
Alright 👍🏻 |
I won't be able to give this time but if anyone else wants to go ahead, please do so. |
Okay, I want to contribute to the CockroachDB since this issue gets available I'm willing to pick it. :) |
Trying to get my head around the codebase. So far, I have failed miserably but anyway I'm going to try again until this doesn't get fixed. @rafiss I have done the suggested changes except for the actual implementation which is going to be in In the |
@iAziz786 thanks for your interest! for this issue, we are trying to change the formatting logic for floating point values. the original issue report talks about how JDBC cannot parse the value that is sent out by CockroachDB. so the goal here is to change what CockroachDB is outputting; the goal is not to change any parsing logic in CockroachDB. also, i realized i made a mistake earlier: we need to update to answer your question, in
add in a few new |
* Create missing profiles for H2, in pom and github workflows * Add test classpath for H2 remote, so that UDF tests can run * Make each H2 test config use different directories/ports * Enable CockroachDB engine schema tests (required upgrading Docker image version, due to a bug cockroachdb/cockroach#62601) * Add flag to MySQL test configs to allow connecting to newer versions of the server * Other improvements and cleanups
* Create missing profiles for H2, in pom and github workflows * Add test classpath for H2 remote, so that UDF tests can run * Make each H2 test config use different directories/ports * Enable CockroachDB engine schema tests (required upgrading Docker image version, due to a bug cockroachdb/cockroach#62601) * Add flag to MySQL test configs to allow connecting to newer versions of the server * Other improvements and cleanups Co-authored-by: José Fidalgo <jose.fidalgo@feedzai.com>
Describe the problem
PostgreSQL supports
'Inf'
as a valid literal for the floating point special value Infinity, but the JDBC driver can't seem to read it from CockroachDBTo Reproduce
Expected behavior
This works as expected in PostgreSQL, producing 2 times
Infinity
, but it doesn't work on CockorachDB, where I'm getting this error:One could argue the JDBC driver should understand it as well given that I can use the string literal in casts, too, even in PostgreSQL (
'Inf'::real
). But for interoperability reasons, but as it stands now, I can't seem to read these values from JDBC in CockroachDB, short of reading strings.I've also created an issue in pgjdbc to suggest supporting parsing
Inf
: pgjdbc/pgjdbc#2109Environment:
The text was updated successfully, but these errors were encountered: