Hello OHDSI community. I am trying to run an R study package generated in the population level estimation. When running the execute function.
** ERROR IN CONSOLE **
Error in execute(connectionDetails = connectionDetails, cdmDatabaseSchema = cdmDatabaseSchema, :
1 assertions failed:
- Variable ‘dbms’: Must be element of set {‘sql server’, ‘oracle’, ‘postgresql’, ‘pdw’, ‘impala’, ‘netezza’, ‘bigquery’, ‘spark’, ‘sqlite’, ‘redshift’, ‘hive’, ‘sqlite extended’}, but types do not match (character != factor).
** CODE EXECUTED **
#Set and view environment variable
Sys.setenv(“DATABASECONNECTOR_JAR_FOLDER” = “/home/ohdsi/JDBC/”)
Sys.getenv(“DATABASECONNECTOR_JAR_FOLDER”)
downloadJdbcDrivers(“postgresql”)
Database connection string
connectionDetails ← createConnectionDetails(
dbms = “postgresql”,
server=“localhost/omop”,
user="**",
password="****",
port=“5432”,
pathToDriver ="/home/ohdsi/JDBC/" )
oracleTempSchema ← NULL
options(andromedaTempFolder= “/home/ohdsi/temp/”)
execute(connectionDetails = connectionDetails,
cdmDatabaseSchema = cdmDatabaseSchema,
cohortDatabaseSchema = cohortDatabaseSchema,
cohortTable = cohortTable,
oracleTempSchema = oracleTempSchema,
outputFolder = outputFolder,
databaseId = databaseId,
databaseName = databaseName,
createCohorts = TRUE,
synthesizePositiveControls = FALSE,
runAnalyses = TRUE,
packageResults = TRUE,
maxCores = 1)
- I have downloaded the postgresql driver and the .jar file is available in the path to driver
- Specified “postgresql” in the connection string
- Run the execute function
Correct me if I am wrong, Thank you in advance.