diff --git a/onprc_ehr/resources/etls/eIACUCtoPrimteProtocols.xml b/onprc_ehr/resources/etls/UpdateEhrProtocols.xml similarity index 55% rename from onprc_ehr/resources/etls/eIACUCtoPrimteProtocols.xml rename to onprc_ehr/resources/etls/UpdateEhrProtocols.xml index ea306a7b2..9ddf6dec9 100644 --- a/onprc_ehr/resources/etls/eIACUCtoPrimteProtocols.xml +++ b/onprc_ehr/resources/etls/UpdateEhrProtocols.xml @@ -2,36 +2,31 @@ - eIACUC to Prime Protocols - - Runs stored Procedure to update eiACUC Protocols in ehr + Update Protocols in EHR + Runs stored procedures to update the protocol table in schema ehr. - Runs a stored procedure that generates lab values + Determines and populates BaseProtocol and RevisionNumber data for the protocol table in schema onprc_ehr. - Runs a stored procedure that generates lab values + Adds enddate data to the protocol table in ehr. - - - - + --> diff --git a/onprc_ehr/resources/schemas/dbscripts/sqlserver/onprc_ehr-24.004-24.005.sql b/onprc_ehr/resources/schemas/dbscripts/sqlserver/onprc_ehr-24.004-24.005.sql index aa6901fa0..8dafb5690 100644 --- a/onprc_ehr/resources/schemas/dbscripts/sqlserver/onprc_ehr-24.004-24.005.sql +++ b/onprc_ehr/resources/schemas/dbscripts/sqlserver/onprc_ehr-24.004-24.005.sql @@ -15,7 +15,7 @@ WITH ApprovedProtocols AS ( FROM onprc_ehr.eIACUC_PRIME_VIEW_PROTOCOLS WHERE - Protocol_State IN ('approved','expired', 'terminated', 'withdrawn') + Protocol_State IN ('approved','expired', 'terminated') GROUP BY BaseProtocol ), @@ -44,4 +44,4 @@ Update p Set p.enddate = getDate() , p.contacts = 'EndDated based on Protocol_State ' + e.PROTOCOL_State from ehr.protocol p inner join expiredProtocol e on p.external_id = e.BaseProtocol -END \ No newline at end of file +END