Print Page as PDF
DBIA4513 ICR (4513)

DBIA4513    ICR (4513)

Name Value
NUMBER 4513
IA # 4513
DATE CREATED 2006/01/27
CUSTODIAL PACKAGE MENTAL HEALTH
USAGE Controlled Subscription
TYPE Routine
DBIC APPROVAL STATUS APPROVED
ROUTINE YTQAPI5
NAME DBIA4513
GENERAL DESCRIPTION
This API is called to return data associated with the
administration of all a patient's Mental Health interviews, surveys and tests
(instruments).  The input is an array that includes the patients DFN and a
completion indicator ("Y" for the completed administrations or "N" for the
non-completed administrations).  Output is returned in an array that includes
the administration number, instrument name, date the instrument was given,
date the instrument was saved, who ordered the instrument, who administered
the instrument, was the administration signed, number of questions answered by
the patient, did the user have the specified key to view the instrument's
report, is the instrument legacy (contained in the MH INSTRUMENT file (#601)),
the instrument IEN from the MH TESTS AND SURVEYS file (#601.71), the
instrument IEN from the MH INSTRUMENT file (#601), is the instrument
copyrighted and the IEN of the HOPSITAL LOCATION file (#44).

STATUS Active
DURATION Till Otherwise Agreed
ID YTQAPI5
COMPONENT/ENTRY POINT
COMPONENT/ENTRY POINT COMPONENT DESCRIPTION VARIABLES
ADMINS(YSDATA,YS)
Use D ADMINS^YTQAPI5(.YSDATA,.YS) to call the api.  A
successful call of the api will return YSDATA(1)=[DATA] and YSDATA(2)="# of
administrations returned" followed by the data.

If an error occurs during processing of the input array the api will return
YSDATA(1)="[ERROR]" and YSDATA(2)="error message".

VARIABLES TYPE VARIABLES DESCRIPTION
YS Input
YS("DFN") = Patient IEN of the PATIENT file (#2)
YS("COMPLETE") = If "Y" returns all completed instrument administrations for
the selected patient. If "N" returns all incomplete
instrument
administrations for the selected patient.
Example
-------
YS("DFN")=28
YS("COMPLETE")="Y"

YSDATA Output
OUTPUT = ADMINISTRATION NUMBER field (#.01) of the MH
ADMINISTRATIONS file
(#601.84)^INSTRUMENT NAME field (#2) of the MH ADMINISTRATIONS file
(#601.84)^ DATE GIVEN field (#3) of the MH ADMINISTRATIONS file
(#601.84)^DATE SAVED field (#4) of the MH ADMINISTRATIONS file
(#601.84)^ORDERED BY field (#5) of the MH ADMINISTRATIONS file
(#601.84)^ADMINISTERED BY field (#6) of the MH ADMINISTRATIONS file
(#601.84)^SIGNED field (#7) of the MH ADMINISTRATIONS file (#601.84)
^NUMBER OF QUESTIONS ANSWERED field (#9) of the MH ADMINISTRATIONS
file (#601.84)^R PRIVILEGE field (#9) of the MH TESTS AND SURVEYS
file
(#601.71) or EXEMPT TEST field (#21) of MH INSTRUMENT file (#601)^IS
LEGACY field (#9) of the MH TESTS AND SURVEYS file (#601.71)^
INSTRUMENT IEN From the MH TESTS AND SURVEYS file (#601.71)^
INSTRUMENT IEN From the MH INSTRUMENT file (#601)^REQUIRES LICENSE
field (#11) of the MH TESTS AND SURVEYS file (#601.71) or LICENSE
STATUS field (#35) of the MH INSTRUMENT file (#601)^IEN OF HOPSITAL
LOCATION file (#44)

Example of a patient with input variable YS("COMPLETE")="Y"
-----------------------------------------------------------
YSDATA(1)="[DATA]"
YSDATA(2)="20 administrations returned"
YSDATA(3)="91^AUDC^3060126.095539^3060126.105625^232^232^N^3^^Y^5^208^N^78"
YSDATA(4)="88^PTSD4Q^3060125.15163^3060125.161933^232^232^N^4^^N^56^^N^48"

YSDATA(5)="66^DOM80^3060117.134325^3060117.144433^232^232^N^4^^Y^19^229^N^78"

YSDATA(6)="65^DOM80^3060117.125948^3060117.140054^232^232^N^4^^Y^19^229^N^78"

YSDATA(7)="64^DOM80^3060117.124934^3060117.135559^232^232^N^4^^Y^19^229^N^78"
YSDATA(8)="^DOM80^3060117^3060117^232^232^^^Y^Y^^229^N^"
YSDATA(9)="59^PTSD4Q^3060113.144201^3060113.154602^232^232^N^4^^N^56^^N^78"
YSDATA(10)="57^PTSD4Q^3060113.142601^3060113.153132^232^232^N^4^^N^56^^N^78"
YSDATA(11)="51^PTSD4Q^3060111.143238^3060111.155526^232^232^N^4^^N^56^^N^29"

YSDATA(12)="101268^CAGE^3051025.140555^3051025.160642^6620^6620^N^4^^Y^17^226
^N^2"
YSDATA(13)="101267^CAGE^3051025.14002^3051025.160041^6491^6491^N^4^^Y^17^226
^N^2"
YSDATA(14)="101144^BDI2^3050906.113933^3050906.124137^232^232^N^21^^Y^11^245
^Y^29"
YSDATA(15)="101118^CAGE^3050902.110511^3050902.13054^6491^6491^N^4^^Y^17^226
^N^2"
YSDATA(16)="101035^AUDIT^3050714.132436^3050714.160933^232^232^N^10^^Y^7^227
^Y^29"
YSDATA(17)="101029^BDI2^3050714.110644^3050714.121118^232^232^N^21^^Y^11^245
^Y^29"
YSDATA(18)="101028^AUDIT^3050714.110035^3050714.120554^232^232^N^10^^Y^7^227
^Y^29"
YSDATA(19)="101027^AUDC^3050714.105908^3050714.120025^232^232^N^3^^Y^5^208^N
^29"
YSDATA(20)="101026^AUDC^3050714.105805^3050714.115853^232^232^N^3^^Y^5^208^N
^29"
YSDATA(21)="100957^AUDC^3050614.125945^3050614.140836^232^232^N^3^^Y^5^208^N
^7"
YSDATA(22)="100958^ZDIT-2005^3050614.125945^3050614.140843^232^232^N^12^^N^
100087^^N^7"

Example of a patient with input variable YS("COMPLETE")="N"
-----------------------------------------------------------
YSDATA(1)="[DATA]"
YSDATA(2)="2 administrations returned"
YSDATA(3)="^MMPI2^2940809^^176^^^500^^Y^^202^N^"
YSDATA(4)="^MMPI^2930219^2930219^176^^^0^^Y^^60^Y^"

SUBSCRIBING PACKAGE
SUBSCRIBING PACKAGE SUBSCRIBING DETAILS
HEALTH SUMMARY
VIRTUAL PATIENT RECORD
Added 9/19/23, to use the ADMINS^YTQAPI5 call for
retrieving completed administrations by patient.
DATE ACTIVATED 2023/09/19