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
Datatype returned as character instead of double since fix of issue #83 #90
Comments
I am having a similar issue pulling data from a Denodo data virtualization server, in which |
@s-u What is your opinion on this issue? |
@pascalgulikers I don't have access to SAP so I would need more details on what exactly is the exact SQL type and what happens there. The report lacks any and all details (screenshots are not helpful, use R tools like |
@s-u can you say what information exact you need to investigate this issue. Then I can see if I can retrieve that information. I am a collegae of Pascal and have access to SAP HANA. |
require(devtools)
|
devtools::install_version("RJDBC", version = "0.2-10", repos = "http://cran.us.r-project.org/")
Note: Of course there are R packages which could convert strings into numeric. However, with high precision in HANA this results in incorrect values because of rounding differences. |
@s-u Do you have an update on this issue? Do you have enough information? |
@pascalgulikers The data type in the database is not representable as numeric in R, so the only type in R that can represent it without loss of precision is a string. Previous versions would incorrectly convert such numbers to numeric vectors, but that could cause loss of precision. So the current behavior is correct. You can use Rmpfr to deal with numbers that are beyond the IEEE double precision or if you are ok with losing precision you can use |
We have the same issue when querying columns with type BIGINT from Impala. we receive them as characters. But if we query columns of type DOUBLE we receive numeric values as expected. |
Since version 0.2-10 there are some issues with datatype conversion from SAP HANA tables. High precision 0 values return as character 0E-8 instead of double 0.0000000
RJDBC 0.2-08:
RJDBC 0.2-10
Possible fix in class.R line 454:
l[[i]] <- numeric()
cp <- .jcall(res@md, "I", "getPrecision", i)
if (cp > 15) {
l[[i]] <- character()
rts[i] <- 1L
}
The text was updated successfully, but these errors were encountered: