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

Use typeof() to detect data type #95

merged 3 commits into from Feb 10, 2016


Copy link

commented Feb 9, 2016

instead of class().


this will give better default behaviour for base vectors with classes that we don't know how to deal with otherwise.

Kirill Müller added some commits Feb 8, 2016

Kirill Müller
use typeof() to detect data type
instead of class().
R/upload.r Outdated
stop("Unknown class ", paste0(class(x), collapse = "/"))
if (is.factor(x)) return("STRING")
if (inherits(x, "POSIXct")) return("TIMESTAMP")

This comment has been minimized.

Copy link

hadley Feb 10, 2016


This should test for "POSIXt"

Kirill Müller

hadley added a commit that referenced this pull request Feb 10, 2016

Merge pull request #95 from krlmlr/feature/upload-typeof
Use typeof() to detect data type

@hadley hadley merged commit b4f438b into r-dbi:master Feb 10, 2016

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
2 participants
You can’t perform that action at this time.