VistA Analysis » VistA Reference » RPCs » VBECS MED PROFILE LOOKUP


This RPC returns XML containing a list of medications for a patient from the Pharmacy package within a given date range. The patient demographic data is provided by the VistA API DEM^VADPT in the VADM array. The medication related data is provided by the Pharmacy API OCL^PSOORRL inthe ^TMP(“PS”,$J global array in the following format. ^TMP(“PS”,$J,D0,0)=ORDER #_File;PKG^DRUG^INFUSION RATE^STOP DATE^REFILLSREMAINING^TOTAL DOSE^UNITS PER DOSE^PLACER #^STATUS^LAST FILLDATE^DAYSSUPPLY^QUANTITY^NOT TO BE GIVEN^PENDING RENEWAL (1 or 0)^ISSUEDATE(Outpatient) or START DATE(Inpatient)^LAST RELEASE DATE/TIME^LAST FILLDAY SUPPLY XML Mapping:PatientName element = VADM(1)PatientSsn element = VADM(2)PatientDob element = VADM(3) in HL7 formatBeginningSearchDate element = SDATE input parameter in HL7 formatEndingSearchDate element = EDATE input parameter in HL7 formatOrderNumber element = ORDER #DrugName element = DRUGIssueStartDate element = ISSUE DATE(Outpatient) or START DATE(Inpatient)Status element = STATUSInpatientOutpatientIndicator = PKG XML Example: VBECSpatient,One 666-66-6666 Jan 01, 1900 Oct 01, 2002 Jul 31, 2003 4863015 ACETAMINOPHEN 500MG TAB Apr 08, 2002 EXPIRED O


Property Value
Label RX
MUMPS Implementation VBECRPCP

Input Parameters

Name Type Maximum Data Length Required Description
SDATE LITERAL 30 true The SDATE input parameters represents the start date required by the Pharmacy API OCL^PSOORRL.
EDATE LITERAL 30 true The EDATE input parameter represents the end date required by the Pharmacy API OCL^PSOORRL.
DFN LITERAL 15 true The VistA Patient file (#2) Internal Entry Number.

Document generated on August 31st 2022, 2:55:43 pm