EHDEN / Trajectories

5 stars 2 forks source link

Error with 1CohortCC.sql: Invalid column name 'TRUE' #8

Closed solis9753 closed 4 years ago

solis9753 commented 4 years ago

I am getting the following error while running createEventPairsTable function:

Error: Error executing SQL: com.microsoft.sqlserver.jdbc.SQLServerException: Invalid column name 'TRUE'. An error report has been created at Trajectories/errorReportSql.txt

errorReportSql.txt

Looking at 1CohortCC.sql file, the error is caused at the first instance where ...WHERE TRUE=@addConditions is used.

"TRUE" is not a column name as the Error message suggests therefore may be related to #5 ?

solis9753 commented 4 years ago

Hi @SulevR, did you have a look at this?

SulevR commented 4 years ago

Yes @solis9753, we are working on that. We hoped that SQL Server syntax is more similar to other SQL engines but it seems from your issue reports that it has (too) many differences and we cannot get rid of the problems without installing SQL Server for ourselves also. So we are currently trying to install it. I guess it takes some time to get it solved.

Kadri0 commented 4 years ago

Hi @solis9753 we have addressed the SQL Server syntax problems in the latest update. I tested the package on a local SQL Server containing empty OMOP CDM tables. This means I couldn't test the createIgraph.R script, but all the other scripts should work (hopefully createIgraph.R too).

NB! We also changed CodeToRun.R a bit.