Skip to content

Commit

Permalink
Merge pull request #414 from palladiumkenya/Feauture--Cleaning-Regimens
Browse files Browse the repository at this point in the history
Clean Regimen Lines
  • Loading branch information
Marymary-dev authored Apr 29, 2024
2 parents 9bdb3c3 + 0fa3d32 commit fded5fa
Showing 1 changed file with 11 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -152,9 +152,17 @@ INNER JOIN ods.dbo.lkp_patient_source ON lkp_patient_source.source_name = ARTPat
GO


-- TODO: clean Start RegimenLine
-- clean Start RegimenLine
UPDATE ODS.DBO.CT_ARTPatients
SET StartRegimenLine = ODS.dbo.lkp_RegimenLineMap.Target_Regimen
FROM ODS.DBO.CT_ARTPatients AS ARTPatients
INNER JOIN ods.dbo.lkp_RegimenLineMap ON lkp_RegimenLineMap.Source_Regimen = ARTPatients.StartRegimenLine




-- TODO: clean Last RegimenLine
GO
-- clean Last RegimenLine
UPDATE ODS.DBO.CT_ARTPatients
SET LastRegimenLine = ODS.dbo.lkp_RegimenLineMap.Target_Regimen
FROM ODS.DBO.CT_ARTPatients AS ARTPatients
INNER JOIN ods.dbo.lkp_RegimenLineMap ON lkp_RegimenLineMap.Source_Regimen = ARTPatients.LastRegimenLine

0 comments on commit fded5fa

Please sign in to comment.