$$PRENDIAG(DFN,BDT,ENCDATE,.DIAGLIST) |
This API searches the V POV file for previous
encounter diagnoses for a patient using the Clinical Reminders Index. The
arguments are:
DFN - The patient
BDT - Each V POV entry has an associated date, this is the Event Date and
Time and if that does not exist it is the Visit/Admit Date&Time. This argument
specifies how far back to start the search. It can be any valid FileMan date
including symbolic dates of the form T-NX where N is an integer and X can be
one of the following:
D = days
M = months
Y = years
T-3M would start the search three months prior to today, T-2Y would start the
search 2 years prior to today.
ENCDATE - The encounter date, only diagnoses that are active as of the
encounter date will be returned.
DIAGLIST - The list of diagnoses that were found, this is in a format that is
compatible with the API GETLST^IBDF18A, so that the list created by this API
can be passed into GETLST^IBDF18A and have the additional diagnoses defined
for a specified encounter form added to the list.
DIAGLIST(0)=The number that were found
DIAGLIST(1)="^PREVIOUS ENCOUNTER DIAGNOSES"
DIAGLIST(2) to DIAGLIST(2+number found) An "^" separated string where
Piece 1 is the code
Piece 2 is the short description of the code
Piece 9 is the code pointer, the internal entry number of the code in file
#80
Piece 10 is the long description of the code
If no diagnoses are found then DIAGLIST(2)="^None found"
The return values are:
-1 - The Clinical Reminders Index for V POV is missing so the search cannot
be performed
N - The number of diagnoses that were found
For a diagnosis to be added to the list it must be associated with an
encounter that has a status of "CHECKED OUT" and not already on the patient's
Problem List.
|
VARIABLES |
TYPE |
VARIABLES DESCRIPTION |
DFN |
Input |
Patient
|
BDT |
Input |
Date and optional time to start the search
|
ENCDATE |
Input |
Encounter date and optional time
|
DIAGLIST |
Output |
The list of diagnoses
|
|