Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Info |  Source |  Call Graph |  Entry Points |  External References |  Interaction Calls |  Global Variables Directly Accessed |  Label References |  Local Variables |  All
Print Page as PDF
Routine: BMXADOX1

Package: M Transfer

Routine: BMXADOX1


Information

BMXADOX1 ; IHS/CIHA/GIS - RPC CALL: GENERATE AN ADO SCHEMA STRING AND DATA SET ;

Source Information

Source file <BMXADOX1.m>

Call Graph

Call Graph Total: 3

Package Total Call Graph
M Transfer 3 SS^BMXADO  BAFM^BMXADOF1  DISP^BMXADOX  

Entry Points

Name Comments DBIA/ICR reference
AA ; ITERATE USING AA INDEX
; INDEX IS 'AA" THE START AND STOP DATES ARE SPECIFIED IN EXTERNAL FORMAT. MAX=10
; THE FOLLOWING FILTERS ARE SPECIFIED IN THE LAST PARAMETER ("1|WT|C"):
; 1=PATIENT DFN #1
; WT=RETURN ONLY WEIGHTS. MEASUREMENT TYPE MUST BE SPECIFIED WITH A VALID, UNAMBIGUOUS LOOKUP VALUE.
; C=RETRUN VALUES IN CHRONOLOGICAL ORDER USE 'R' INSTEAD OF 'C' FOR REVERSE CHRONOLOGICAL ORDER. DEFAULT=C
; THE SEED PARAMTER IS SET AND CAN BE USED TO RETURN DATA IN CHUNKS
SUB ; SUBFILE ITERATION
; THE SCHEMA IS ATTACHED TO THE MEDICARE ELIGIBILITY FILE/ELIG DATE SUBFILE
; THE DA STRING HAS A VALUE OF '1,',: THE IEN IN THE PARENT FILE.
; NOTE THE COMMA IN THE DA STRING. THIS INDICATES THAT THE FILE IEN IS 1 BUT THE SUBFILE IEN IS UNSPECIFIED
JVPT ; JOIN PT DEMOG TO VISIT
NOTES ; RETURN NOTES FOR A SPECIFIC PATIENT PROBLEMS
CIT ; CUSTOM ITERATOR
; IF COMPLEX OR UNUSUAL SORTING/FILTERING IS REQUITED, USE A CUSTOM ITERATOR
; THE CUSTOM ITERATOR IS DEFINED BY 6TH, 7TH AND 8TH PIECES IN THE VSTG
; PIECE 8=TAG, PIECE 9=ROUTINE, PIECE 8=A PARAMETER PASSED TO THE ENTRY POINT
; THE 9TH PIECE CONTAINS PT DFN, TIMESTAMP, VISIT TYPE, LOC IEN, AND SERVICE CATEGORY IN A "|" DELIMTED STRING
; THE ITERATOR CALL TAG^ROUTINE(PARAM) TO GENERATE IENS
; IN THIS CASE THE SCHEMA IS ATTACHED TO THE VISIT FILE.
; GIVEN THE INFORMATION IN THE PARAMETER, THE CUSTOM ITERATOR RETURNS POSSIBLE DUPLICATE VISITS
DELVAL ; DELETE A VALUE IN A FIELD
; SIMILAR TO EDIT EXCEPT THE VALUE IS "@"
PB1 ; ALT PROB RETRIEVAL TEST
POV ; RETURN THE POV SCHEMA
RIT
JAC ; TEST AC INDEX
NUM ; ITERATE BY IEN
; IX="",START WITH IEN=1, STOP AFTER IEN=20, MAX # RECORDS RETURNED = 5
; TO VIEW INTERNAL VALUES SET VSTG="~1~20~5~I"
DINUM ; DINUMED POINTER ITERATION
; THE SCHEMA IS ATTACHED TO THE IHS PATIENT FILE (9000001)
; THE IHS PATIENT FILE IS DINUM'D AND ITS .01 FIELD POINTS TO THE VA PATIENT FILE (2)
; BECAUSE OF THE SPECIAL RELATIONSHIP BETWEEN THE FILES, WE CAN USE THE B INDEX OF FILE 2 TO ITERATE FILE 9000001.
JMD ; JOIN MASTER TO DETAIL
DISP(OUT) ;
IX ; ITERATE BY INDEX
; ITERATE USING THE "B" INDEX
; START WITH PT NAME "C", STOP AFTER PATIENT NAME = "D", MAX # RECORDS RETURNED = 5
DELREC ; DELETE AN ENTRY
; THE SIMPLEST WAY TO DELETE AN ENTRY IS TO PUT THE RECORD IEN IN THE DA STRING PRECEDED BY A MINUS SIGN
; YOU CAN ALSO SET THE VALUE OF THE .01 FIELD TO "@"
; IF THE VALUE OF THE .01 FIELD IS NULL AND THE DA STRING IS NOT PRECEDED BY A MINUS SIGN, THE TRANSACTION WILL BE CANCELLED
; IF THE DA STRING IS NULL, THE TRANSACTION WILL BE CANCELLED
VCN ; SHOW VALUES FOR A SINGLE VISIT THAT AS A DEFINED VCN
JSUB ; SUBFILE JOIN
; IN THIS CASE THE RECORDS IN A PARENT FILE ARE "JOINED" TO THE RECORDS IN ONE OF ITS SUB FILES
; THE SCHEMA IS ATTACHED TO THE "MEDICARE ELIGIBLE" FILE
; IT IS JOINED TO ITS SUBFILE, "ELIG DATES", VIA THE UPDATE MEDICARE DATES SCHEMA
ADD ; ADD A NEW ENTRY
; THIS IS A 2 STEP PROCESS:
; FIRST GET THE SCHEMA FOR THE FILE YOU WISH TO UPDATE
; THIS SCHEMA TYPICALLY BEGINS WITH THE WORD "UPDATE"
; IT CONTAINS NO ID IR IEN FIELDS
; SECOND ADD THE DATA NODE TO THE ARRAY
; IT HAS THE SAME FORMAT AS A DATA STRING ASSOCIATED WITH THE SCHEMA EXCEPT THE FIRST "^" PIECE IS NULL
; THIS PIECE CORRESPONDS TO THE IEN OF THE RECORD. SINCE THE RECORD HASNOT BEEN ADDED YET, IT IS NULL.
; IN THE DATA STRING, ALL POINTER VALUES ARE PRECEDED BY THE '`' CHARACTER AND EA. STRING ENDS IN $C(30)
; MULTIPLE DATA STRINGS CAN BE APPENDED AS NEW NODES AT THE BOTTOM OF THE ARRAY
; IN THIS CASE WE ARE ADDING A RECORD TO THE V MEASUREMENT FILE
; DATA STRING="^MEASUREMENT TYPE IEN^PATIENT DFN^VISIT IEN^RESULT"_$C(30)
; THERE ARE 2 INPUT PARAMS:
; THE CLOSED REF WHERE THE INPUT ARRAY IS STORED
; SINCE IT IS PASSED BY REFERENCE "OUT" CAN BE NULL OR UNDEFIEND.
; OUT WILL BE DEFINED AT THE CONCLUSION OF THE TRANSACTION.
; THE OUTPUT IS IN THE OUT ARRAY
; OUT(1)="OK|ien" WHERE ien IS THE IEN OF THE RECORD THAT HAS BEE ADDED.
; IF THE TRANSACTION FAILED, AN ERROR MSG WILL BE IN THE OUT ARRAY
TRIGGER ; TEXT TRIGGER FUNCTION
RENT ; ITERATE IN CHUNKS
; RE-ITERATE USING THE "B" INDEX
; START WITH PT IEN 5 AS THE "SEED", STOP AFTER PATIENT NAME = "D", MAX # RECORDS RETURNED = 5
IXP ; INDEXED POINTER ITERATION
; THE SCHEMA IS ATTACHED TO THE V POV FILE
; THE AC CROSS REFERENCE INDEXES THE PATIENT FIELD
; BY STARTING AND STOPING WITH PATIENT 1 (MAX=5) WE COLLECT THE FIRST 5 POVS FOR PATIENT 1 IN THE FILE
ID ; IDENTIFIER FIELD
; THE SCHEMA IS ATTACHED TO THE VA PATIENT FILE (2)
; THE SCHEMA HAS A BUILT IN FIELD (.01ID) THAT RETURNS THE IDENTIFIERS
; THE ENTRY POINT THAT GENERATES THE IDETIFIERS IS STORED IN THE BMX ADO SCHEMA FILE
SCHEMA(NAME) ; GIVEN SCHEMA NAME, RETURN THE IEN
EDIT ; EDIT AN EXISTING ENTRY
; SIMILAR TO ABOVE EXCEPT THAT THE FIRST "^" PIECE OF THE DATA NODE IS THE IEN OF THE RECORD TO BE EDITIED
; NOTE THAT THERE IS NO '`' IN FRONT OF THE FIRST PIECE. IT IS A PURE INTEGER
JPB ; TEST AA INDEX JOINS FOR PROBLEM LIST
MT ; MEASUREMNT TYPES
AA2 ; ITERATE USING AA INDEX
; THIS SCHEMA IS ATTACHED TO THE VISIT FILE (9000010)
; IN THIS CASE THERE IS NO ATTRIBUTE TYPE SO THE FILTER PARAM HAS ONLY 2 PIECES "1|R"
; 1=PATIENT DFN
; R=RETURN DATA IN REVERSE CHRONOLOGICAL ORDER
PROB ; PATIENT PROBLEMS

External References

Name Field # of Occurrence
SS^BMXADO NUM+5, IX+5, VCN+3, MT+3, PROB+3, PB1+3, POV+3, NOTES+3, RIT+2, SUB+6
, DINUM+6, IXP+6, AA+9, AA2+7, CIT+10, TRIGGER+3, ID+6, JMD+8, JVPT+6, JAC+5
, JPB+4, JSUB+7, ADD+22, DELREC+8, EDIT+5, DELVAL+4
BAFM^BMXADOF1 ADD+26, DELREC+12, EDIT+9, DELVAL+8
DISP^BMXADOX DISP+1

Interaction Calls

Name Line Occurrences
Function Call: READ
  • Timeout: $G(DTIME,60)
  • Variable: %
  • Line Location: RIT+3
Function Call: READ
  • Timeout: $G(DTIME,60)
  • Variable: %
  • Line Location: ADD+25
Function Call: WRITE
  • Prompt: !,OUT(%)
  • Line Location: ADD+28
Function Call: READ
  • Timeout: $G(DTIME,60)
  • Variable: %
  • Line Location: DELREC+11
Function Call: WRITE
  • Prompt: !,OUT(%)
  • Line Location: DELREC+14
Function Call: READ
  • Timeout: $G(DTIME,60)
  • Variable: %
  • Line Location: EDIT+8
Function Call: WRITE
  • Prompt: !,OUT(%)
  • Line Location: EDIT+11
Function Call: READ
  • Timeout: $G(DTIME,60)
  • Variable: %
  • Line Location: DELVAL+7
Function Call: WRITE
  • Prompt: !,OUT(%)
  • Line Location: DELVAL+10

Global Variables Directly Accessed

Name Line Occurrences  (* Changed,  ! Killed)
^BMXADO("B" SCHEMA+2
^TMP("BMX ADO" NUM+7!, IX+7!, VCN+5!, MT+5!, PROB+5!, PB1+5!, POV+5!, NOTES+5!, RIT+9!, SUB+8!
, DINUM+8!, IXP+8!, AA+11!, AA2+9!, CIT+12!, TRIGGER+5!, ID+8!, JMD+10!, JVPT+8!, JAC+7!
, JPB+6!, JSUB+9!, ADD+23, ADD+24*, ADD+26, ADD+27!, DELREC+9, DELREC+10*, DELREC+12, DELREC+13!
, EDIT+6, EDIT+7*, EDIT+9, EDIT+10!, DELVAL+5, DELVAL+6*, DELVAL+8, DELVAL+9!

Label References

Name Line Occurrences
$$SCHEMA NUM+4, IX+4, VCN+2, MT+2, PROB+2, PB1+2, POV+2, NOTES+2, RENT+5, SUB+5
, DINUM+5, IXP+5, AA+8, AA2+6, CIT+9, TRIGGER+2, ID+5, JMD+2, JMD+3, JMD+4
, JVPT+2, JVPT+3, JAC+2, JAC+3, JAC+4, JPB+2, JPB+3, JSUB+5, JSUB+6, ADD+21
, DELREC+7, EDIT+4, DELVAL+3
DISP NUM+6, IX+6, VCN+4, MT+4, PROB+4, PB1+4, POV+4, NOTES+4, RIT+3, SUB+7
, DINUM+7, IXP+7, AA+10, AA2+8, CIT+11, TRIGGER+4, ID+7, JMD+9, JVPT+7, JAC+6
, JPB+5, JSUB+8, ADD+25, DELREC+11, EDIT+8, DELVAL+7

Local Variables

Legend:

>> Not killed explicitly
* Changed
! Killed
~ Newed

Name Field # of Occurrence
% NUM+3~, NUM+6*, IX+3~, IX+6*, VCN+1~, VCN+4*, MT+1~, MT+4*, PROB+1~, PROB+4*
, PB1+1~, PB1+4*, POV+1~, POV+4*, NOTES+1~, NOTES+4*, RENT+3~, RIT+3*, RIT+4, SUB+4~
, SUB+7*, DINUM+4~, DINUM+7*, IXP+4~, IXP+7*, AA+7~, AA+10*, AA2+5~, AA2+8*, CIT+8~
, CIT+11*, TRIGGER+1~, TRIGGER+4*, ID+4~, ID+7*, JMD+1~, JMD+9*, JVPT+1~, JVPT+7*, JAC+1~
, JAC+6*, JPB+1~, JPB+5*, JSUB+4~, JSUB+8*, ADD+20~, ADD+25*, ADD+28*, DELREC+5~, DELREC+11*
, DELREC+14*, EDIT+3~, EDIT+8*, EDIT+11*, DELVAL+2~, DELVAL+7*, DELVAL+10*
DEL DELREC+5~, DELREC+6*, DELREC+10
DTIME NUM+6, IX+6, VCN+4, MT+4, PROB+4, PB1+4, POV+4, NOTES+4, RIT+3, SUB+7
, DINUM+7, IXP+7, AA+10, AA2+8, CIT+11, TRIGGER+4, ID+7, JMD+9, JVPT+7, JAC+6
, JPB+5, JSUB+8, ADD+25, DELREC+11, EDIT+8, DELVAL+7
IEN SCHEMA+1~, SCHEMA+2*, SCHEMA+3
JSTG JMD+1~, JMD+6*, JMD+7*, JMD+8, JVPT+1~, JVPT+5*, JVPT+6
LSEED RENT+3~, RENT+4*, RIT+7, RIT+8*
NAME SCHEMA~, SCHEMA+2
NODE ADD+20~, ADD+23*, ADD+24, DELREC+5~, DELREC+9*, DELREC+10, EDIT+3~, EDIT+6*, EDIT+7, DELVAL+2~
, DELVAL+5*, DELVAL+6
OUT DISP~, DISP+1, NUM+3~, NUM+5, NUM+6, IX+3~, IX+5, IX+6, VCN+1~, VCN+3
, VCN+4, MT+1~, MT+3, MT+4, PROB+1~, PROB+3, PROB+4, PB1+1~, PB1+3, PB1+4
, POV+1~, POV+3, POV+4, NOTES+1~, NOTES+3, NOTES+4, RENT+3~, RIT+2, RIT+3, RIT+5
, SUB+4~, SUB+6, SUB+7, DINUM+4~, DINUM+6, DINUM+7, IXP+4~, IXP+6, IXP+7, AA+7~
, AA+9, AA+10, AA2+5~, AA2+7, AA2+8, CIT+8~, CIT+10, CIT+11, TRIGGER+1~, TRIGGER+3
, TRIGGER+4, ID+4~, ID+6, ID+7, JMD+1~, JMD+8, JMD+9, JVPT+1~, JVPT+6, JVPT+7
, JAC+1~, JAC+5, JAC+6, JPB+1~, JPB+4, JPB+5, JSUB+4~, JSUB+7, JSUB+8, ADD+20~
, ADD+22, ADD+25, ADD+26, ADD+28, DELREC+5~, DELREC+8, DELREC+11, DELREC+12, DELREC+14, EDIT+3~
, EDIT+5, EDIT+8, EDIT+9, EDIT+11, DELVAL+2~, DELVAL+4, DELVAL+7, DELVAL+8, DELVAL+10
OUT( ADD+28, DELREC+14, EDIT+11, DELVAL+10
SEED RENT+3~, RENT+4*, RIT, RIT+2, RIT+3*, RIT+4*, RIT+6*, RIT+7*, RIT+8
SIEN NUM+3~, NUM+4*, NUM+5, IX+3~, IX+4*, IX+5, VCN+1~, VCN+2*, VCN+3, MT+1~
, MT+2*, MT+3, PROB+1~, PROB+2*, PROB+3, PB1+1~, PB1+2*, PB1+3, POV+1~, POV+2*
, POV+3, NOTES+1~, NOTES+2*, NOTES+3, RENT+3~, RENT+5*, RIT+2, SUB+4~, SUB+5*, SUB+6
, DINUM+4~, DINUM+5*, DINUM+6, IXP+4~, IXP+5*, IXP+6, AA+7~, AA+8*, AA+9, AA2+5~
, AA2+6*, AA2+7, CIT+8~, CIT+9*, CIT+10, TRIGGER+1~, TRIGGER+2*, TRIGGER+3, ID+4~, ID+5*
, ID+6, ADD+20~, ADD+21*, ADD+22, DELREC+5~, DELREC+7*, DELREC+8, EDIT+3~, EDIT+4*, EDIT+5
, DELVAL+2~, DELVAL+3*, DELVAL+4
SIEN1 JMD+1~, JMD+2*, JMD+8, JVPT+1~, JVPT+2*, JVPT+6, JAC+1~, JAC+2*, JAC+5, JPB+1~
, JPB+2*, JPB+4, JSUB+4~, JSUB+5*, JSUB+7
SIEN2 JMD+1~, JMD+3*, JMD+7, JVPT+1~, JVPT+3*, JVPT+5, JAC+1~, JAC+3*, JAC+5, JPB+1~
, JPB+3*, JPB+4, JSUB+4~, JSUB+6*, JSUB+7
SIEN3 JMD+1~, JMD+4*, JMD+6, JAC+4*, JAC+5
U RIT+5
VSTG JMD+1~, JMD+5*, JMD+8, JVPT+1~, JVPT+4*, JVPT+6
X RENT+3~, RIT+5*, RIT+6
Y RENT+3~
Info |  Source |  Call Graph |  Entry Points |  External References |  Interaction Calls |  Global Variables Directly Accessed |  Label References |  Local Variables |  All