-
Notifications
You must be signed in to change notification settings - Fork 18
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
Weaviate int needs to be represented as java Long instead of Double #149
Comments
It's indeed an issue, currently an int stored as I created an example demonstrating the issue here: samos123/weaviate-java-example@e8506e0 It seems it's not able to store the Article wordCount correctly either when using Java client with a long value:
|
I'm starting to wonder maybe the Weaviate docs are incorrect that it uses int64:
|
Does Weaviate int datatype support 64 byte numbers? It feels like support for int64 is flaky so maybe we should just only support int32 in the Java client. Relevant issue: weaviate/weaviate#1563 The docs do mention this: |
Thank @samos123 for reporting the issue. As for relevant issue: weaviate is also affected with rounding problem and should be fixed independently: weaviate/weaviate#1563 (comment) |
In Weaviate the int datatype is represented as int64 however in the Java client it gets converted to a java.lang.Double which is an 8 byte structure to represent floating points.
I suspect if we were to store a value of
9223372036854775807
or-9223372036854775807
in Weaviate of datatype int that the java client wouldn't be able to get the correct value.The text was updated successfully, but these errors were encountered: