From 0b74909b605f230fd117e709b2a1de02e770ab37 Mon Sep 17 00:00:00 2001 From: bbimber Date: Wed, 20 May 2026 15:06:45 -0700 Subject: [PATCH] Support bigint --- Rlabkey/DESCRIPTION | 2 +- Rlabkey/R/makeDF.R | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Rlabkey/DESCRIPTION b/Rlabkey/DESCRIPTION index fe58ab1..d3a97f1 100755 --- a/Rlabkey/DESCRIPTION +++ b/Rlabkey/DESCRIPTION @@ -18,6 +18,6 @@ Description: The 'LabKey' client library for R makes it easy for R users to License: Apache License 2.0 Copyright: Copyright (c) 2010-2018 LabKey Corporation LazyLoad: true -Depends: httr, jsonlite +Depends: httr, jsonlite, bit64 LinkingTo: Rcpp Imports: Rcpp (>= 0.11.0) diff --git a/Rlabkey/R/makeDF.R b/Rlabkey/R/makeDF.R index 7be7a9c..c3229b3 100755 --- a/Rlabkey/R/makeDF.R +++ b/Rlabkey/R/makeDF.R @@ -147,7 +147,7 @@ makeDF <- function(rawdata, colSelect=NULL, showHidden, colNameOpt) try( if(mod=="date") { newdat[,j] <- .parseDate(newdat[,j])} else if(mod=="string"){ suppressWarnings(mode(newdat[,j]) <- "character")} else - if(mod=="int"){ suppressWarnings(mode(newdat[,j]) <- "integer")} else + if(mod=="int"){ suppressWarnings(newdat[,j] <- bit64::as.integer64(newdat[,j]))} else if(mod=="boolean"){suppressWarnings(mode(newdat[,j]) <- "logical")} else if(mod=="float"){suppressWarnings(mode(newdat[,j]) <- "numeric")} else {print("MetaData field type not recognized.")} @@ -163,7 +163,7 @@ makeDF <- function(rawdata, colSelect=NULL, showHidden, colNameOpt) try( if(mod=="date"){ newdat <- .parseDate(newdat)}else if(mod=="string"){suppressWarnings(mode(newdat) <- "character")} else - if(mod=="int"){ suppressWarnings(mode(newdat) <- "integer")} else + if(mod=="int"){ suppressWarnings(newdat[,j] <- bit64::as.integer64(newdat[,j]))} else if(mod=="boolean"){suppressWarnings(mode(newdat) <- "logical")} else if(mod=="float"){suppressWarnings(mode(newdat) <- "numeric")} else {print("MetaData field type not recognized.")}