hannes / MonetDBLite

MonetDB reconfigured as a library
108 stars 11 forks source link

round-trip for time, datetime, timestamps #168

Closed hannes closed 7 years ago

hannes commented 7 years ago

reading those works, but writing from r not yet

mclements commented 7 years ago

Writing Dates from R to MonetDBLite also did not work for me (int vs double). The attached patch seemed to help. Apologies for not providing a full pull request: the GitHub repository is huge. Sincerely, Mark.

write_Date.txt

hannes commented 7 years ago

@mclements, thanks, will add your changes! Also, a shallow clone (git clone --depth=10) might have helped to speed up cloning.

mclements commented 7 years ago

@hannesmuehleisen, unfortunately and surprisingly, IS_NUMERIC(s) is false when IS_INTEGER(s) is true. My original patch may still be required.

Thank you for suggesting the shallow clone -- much better!

hannes commented 7 years ago

err can you please give a minimal R example for me to add to a test case? Sorry for oversight, will fix

mclements commented 7 years ago

I have now (i) produced a pull request and (ii) provided a minimal example in a comment to the pull request. This bug only surfaced from using foreign::read.dta().

On 07/18/2017 12:55 PM, Hannes Mühleisen wrote:

err can you please give a minimal example for me to add to a test case?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/hannesmuehleisen/MonetDBLite/issues/168#issuecomment-316029005, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AAiBCT-GZGgEqIKvAv0N_xdN94dXDa6Pks5sPI8lgaJpZM4ORv6u.

hannes commented 7 years ago

thanks, merged your PR and added a test case based on your code https://github.com/hannesmuehleisen/MonetDBLite/blob/master/tests/testthat/test_02_dbi.R#L385