Open
Conversation
Changes to test fix for cd_characterisation SQL error at app runtime
Update 2 to correct main.database_meta_data.databasename to cdm_source_name
db.database_name becomes db.cdm_source_name
Release v2.1.1
Release V 2.1.2
Hotfix 3.1.3
Hotfix 2.1.14
Collaborator
|
OK - this was a very complex issue. The problem is that the database tables/prefix and column names can change depending on how the app is being used. If running cohort generator then cohort diagnostics via Strategus you end up with database_meta_data but if running cohort diagnostic alone you end up using a different table in cohort diagnostics. I've made edits to fix the bug for the Strategus way (which based on your edits are how you are using it) in branch issue_211 but I need to test it on the cohort diagnostics only way before I pull these edits in. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#210 (comment)
I've found a fix by correcting the SQL and parameters in the OhdsiShinyModules/R/cohort-diagnostics-characterization.R file.
I first updated the @results_database_schema.@database_table to hardcode .database_meta_data instead, this corrected the table error, but lead to an error with with column names (which had also been meaningless anyway).
I changed db.database_name to db.cdm_source_name which then provided both a fix to the missing characterisation data, error in the time_window view and turned the database names from nonsense -43458720394 to the actual CDM name.
Thanks