Skip to content

Commit d19d2df

Browse files
committed
Revert "fix(sqlData): Convert INTSXP Dates to REALSXP Dates"
This reverts commit d0f7d9e.
1 parent d56eb09 commit d19d2df

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

R/dbi-table.R

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -196,10 +196,6 @@ setMethod("sqlData", "OdbcConnection",
196196
is_IDate <- vapply(value, function(x) is.object(x) && (is(x, "IDate")), logical(1))
197197
value[is_IDate] <- lapply(value[is_IDate], as.Date)
198198

199-
# Convert integer (INTSXP) Date to numeric (REALSXP) Date
200-
is_INTSXP_Date <- vapply(value, function(x) is.object(x) && (is(x, "Date") && is.integer(x)), logical(1))
201-
value[is_INTSXP_Date] <- lapply(value[is_INTSXP_Date], function(x) as.Date(as.numeric(x)))
202-
203199
# C code takes care of atomic vectors, dates, date times, and blobs just need to coerce other objects
204200
is_object <- vapply(value, function(x) is.object(x) && !(is(x, "POSIXct") || is(x, "Date") || is_blob(x) || is(x, "difftime")), logical(1))
205201
value[is_object] <- lapply(value[is_object], as.character)

0 commit comments

Comments
 (0)