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 |  Caller Graph |  Entry Points |  External References |  Interaction Calls |  FileMan Files Accessed Via FileMan Db Call |  Global Variables Directly Accessed |  Label References |  Local Variables |  All
Print Page as PDF
Routine: PSONVAR1

Package: Outpatient Pharmacy

Routine: PSONVAR1


Information

PSONVAR1 ;BHM/MFR - Non-VA Med Usage Report ;04/10/03

Source Information

Source file <PSONVAR1.m>

Call Graph

Call Graph Total: 6

Package Total Call Graph
Kernel 2 ^%ZISC  ($$FMTE,$$NOW)^XLFDT  
VA Fileman 2 $$GET1^DIQ  ^DIR  
Outpatient Pharmacy 1 $$DEAD^PSONVARP  
Registration 1 (ADD,DEM)^VADPT  

Caller Graph

Caller Graph Total: 1

Package Total Caller Graph
Outpatient Pharmacy 1 PSONVARP  

Entry Points

Name Comments DBIA/ICR reference
EN
END
HDR ; - Prints the Header
PRINT(DFN,ORD) ; - Print a Non-VA Med Order
DT(DT) ; - Convert FM Date to MM/DD/YYYY
SRT(ST) ; - Convert the "1,2,4" (example) to "PATIENT,ORDERABLE ITEM,STATUS"
NDTP
NEXT ; - If not Sorting (already printed), SKIP, otherwise, print the report
TEXT(TEXT,STR,L) ; Formats STR into TEXT array, lines lenght = L
DFN
DATE
CLOSE
ORD

External References

Name Field # of Occurrence
^%ZISC CLOSE
$$GET1^DIQ ORD+12, ORD+13, PRINT+8, PRINT+9, PRINT+25, PRINT+27, PRINT+47
^DIR HDR+3
$$DEAD^PSONVARP DFN+3
ADD^VADPT PRINT+10
DEM^VADPT PRINT+10
$$FMTE^XLFDT HDR+8
$$NOW^XLFDT HDR+8

Interaction Calls

Name Line Occurrences
Function Call: WRITE
  • Prompt: SP2
  • Line Location: NEXT+12
Function Call: WRITE
  • Prompt: SP1
  • Line Location: NEXT+13
Function Call: WRITE
  • Prompt: !!?18,"********** NO DATA TO PRINT **********"
  • Line Location: NDTP+0
Function Call: WRITE
  • Prompt: SP1
  • Line Location: NDTP+2
Function Call: WRITE
  • Prompt: !,"Total: ",PCNT," patient",$S(PCNT>1:"s",1:"")
  • Line Location: NDTP+3
Function Call: WRITE
  • Prompt: " and ",OCNT," order",$S(OCNT>1:"s",1:""),"."
  • Line Location: NDTP+4
Function Call: WRITE
  • Prompt: !,PNAM," (ID:",$S(PSSN:$P(PSSN,"-",3),1:"0000"),")"
  • Line Location: PRINT+11
Function Call: WRITE
  • Prompt: ?46,"Patient Phone #: ",$E($P(VAPA(8),"^"),1,16)
  • Line Location: PRINT+12
Function Call: WRITE
  • Prompt: !?5,"Non-VA Med: ",OINAM
  • Line Location: PRINT+15
Function Call: WRITE
  • Prompt: !?2,"Dispense Drug: ",$E(DGNAM,1,37)
  • Line Location: PRINT+16
Function Call: WRITE
  • Prompt: ?55,"Dosage: ",$E($P(XX,"^",3),1,16)
  • Line Location: PRINT+17
Function Call: WRITE
  • Prompt: !?7,"Schedule: "
  • Line Location: PRINT+18
Function Call: WRITE
  • Prompt: SCH
  • Line Location: PRINT+19
Function Call: WRITE
  • Prompt: ?52,"Med Route: ",$E($P(XX,"^",4),1,35)
  • Line Location: PRINT+20
Function Call: WRITE
  • Prompt: !?16,$E($P(XX,"^",5),$L(SCH)+1,99)
  • Line Location: PRINT+22
Function Call: WRITE
  • Prompt: ?49,"CPRS Order #: ",$P(XX,"^",8)
  • Line Location: PRINT+24
Function Call: WRITE
  • Prompt: !?2,"Documented By: ",$E($$GET1^DIQ(200,+$P(XX,"^",11),.01),1,29)
  • Line Location: PRINT+25
Function Call: WRITE
  • Prompt: ?46,"Documented Date: ",$$DT($P(XX,"^",10))
  • Line Location: PRINT+26
Function Call: WRITE
  • Prompt: !?9,"Clinic: "
  • Line Location: PRINT+28
Function Call: WRITE
  • Prompt: $E($P(XX,"^",12)_" - "_CLNAM,1,33)
  • Condition for execution: $P(XX,"^",12)
  • Line Location: PRINT+28
Function Call: WRITE
  • Prompt: ?51,"Start Date: ",$$DT($P(XX,"^",9)),!
  • Line Location: PRINT+29
Function Call: WRITE
  • Prompt: !
  • Line Location: PRINT+35
Function Call: WRITE
  • Prompt: ?1,"Order Check #",I,": "
  • Line Location: PRINT+36
Function Call: WRITE
  • Prompt: ?17,TXT(K),!
  • Line Location: PRINT+38
Function Call: WRITE
  • Prompt: !
  • Line Location: PRINT+38
Function Call: WRITE
  • Prompt: ?23,TXT(K),!
  • Line Location: PRINT+45
Function Call: WRITE
  • Prompt: !
  • Line Location: PRINT+45
Function Call: WRITE
  • Prompt: ?6,"Override Provider: "
  • Line Location: PRINT+47
Function Call: WRITE
  • Prompt: $$GET1^DIQ(200,+PRV,.01)
  • Condition for execution: PRV
  • Line Location: PRINT+47
Function Call: WRITE
  • Prompt: !
  • Line Location: PRINT+47
Function Call: WRITE
  • Prompt: !,"Statement/Explanation/Comments: "
  • Line Location: PRINT+52
Function Call: WRITE
  • Prompt: ?32,TXT(K),!
  • Line Location: PRINT+57
Function Call: WRITE
  • Prompt: !
  • Line Location: PRINT+57
Function Call: WRITE
  • Prompt: @IOF,"Non-VA Meds Usage Report",?74,"Page: ",$J(PAG,3)
  • Line Location: HDR+5
Function Call: WRITE
  • Prompt: !,"Sorted by",$$SRT(PSOSRT)
  • Line Location: HDR+6
Function Call: WRITE
  • Prompt: !,"Date Range: "_$$DT(PSOSD+1\1)_" - "_$$DT(PSOED\1)
  • Line Location: HDR+7
Function Call: WRITE
  • Prompt: ?48,"Run Date: "_$$FMTE^XLFDT($$NOW^XLFDT())
  • Line Location: HDR+8
Function Call: WRITE
  • Prompt: !,X
  • Line Location: HDR+9
Routine Call
  • DIR
  • Line Location:
    • HDR+3

FileMan Files Accessed Via FileMan Db Call

FileNo Call Tags
^DPT - [#2] GET1^DIQ
^VA(200 - [#200] GET1^DIQ
^SC - [#44] GET1^DIQ
^PSDRUG - [#50] GET1^DIQ
^PS(50.7 - [#50.7] GET1^DIQ

Global Variables Directly Accessed

Name Line Occurrences  (* Changed,  ! Killed)
^PS(55 - [#55] DATE, DFN, ORD, ORD+1, ORD+5, ORD+6, ORD+18, PRINT+5, PRINT+8, PRINT+32
, PRINT+33, PRINT+34, PRINT+40, PRINT+41, PRINT+51, PRINT+53, PRINT+54
^TMP("PSOCNT" EN+3!, END!, PRINT+13*
^TMP("PSONV" EN+3!, ORD+20*, NEXT+3, NEXT+4, NEXT+5, NEXT+6, NEXT+7, NEXT+8, NEXT+9, NEXT+12
, NEXT+13, END!

Label References

Name Line Occurrences
$$DT PRINT+23, PRINT+26, PRINT+29, HDR+7
$$SRT HDR+6
CLOSE ORD+8, NEXT+14
DATE DFN, DFN+1
DFN DFN+3, ORD
HDR ORD+9, NEXT+10, NDTP, PRINT+6, PRINT+35, PRINT+38, PRINT+45, PRINT+57
NDTP NEXT+1
NEXT DATE
ORD ORD+2, ORD+3, ORD+4, ORD+5, ORD+6, ORD+8, ORD+21
PRINT ORD+10, NEXT+11
TEXT PRINT+36, PRINT+42, PRINT+55

Local Variables

Legend:

>> Not killed explicitly
* Changed
! Killed
~ Newed

Name Field # of Occurrence
C EN~
CLNAM PRINT+2~, PRINT+27*, PRINT+28
DATE EN~, EN+7*, DATE*, DFN, ORD, ORD+19
DFN EN~, EN+7*, DFN*, DFN+1*, DFN+3, ORD, ORD+1, ORD+5, ORD+6, ORD+10
, ORD+12, ORD+18, ORD+20, NEXT+2*, NEXT+8*, NEXT+9, NEXT+11, PRINT~, PRINT+5, PRINT+8
, PRINT+13, PRINT+32, PRINT+33, PRINT+34, PRINT+40, PRINT+41, PRINT+51, PRINT+53, PRINT+54
DGNAM PRINT+2~, PRINT+9*, PRINT+16
DIR HDR+1~
DIR("A" HDR+3*
DIR(0 HDR+3*
DIRUT EN+7!, ORD+8, ORD+9, ORD+10, NEXT+3, NEXT+4, NEXT+5, NEXT+6, NEXT+7, NEXT+8
, NEXT+9, NEXT+10, NEXT+12, NEXT+13, NEXT+14, PRINT+6, PRINT+33, PRINT+35, PRINT+37, PRINT+38
, PRINT+39, PRINT+44, PRINT+45, PRINT+46, PRINT+48, PRINT+51, PRINT+56, PRINT+57, HDR+2
DT DT~, DT+1, DT+2, DT+3, DT+4
FLD SRT+3~, SRT+6*
I EN~, ORD+16*, ORD+17, ORD+19, PRINT+2~, PRINT+33*, PRINT+34, PRINT+36, PRINT+40, PRINT+41
, PRINT+53*, PRINT+54, SRT+3~, SRT+5*, SRT+6, SRT+7
IO EN+3
IOF HDR+5
IOSL ORD+9, NEXT+10, PRINT+35, PRINT+38, PRINT+45, PRINT+57
IOST HDR+2
J EN~, PRINT+2~, PRINT+40*, PRINT+41, TEXT+1~, TEXT+2*, TEXT+3
K PRINT+2~, PRINT+37*, PRINT+38, PRINT+44*, PRINT+45, PRINT+56*, PRINT+57, TEXT+1~*, TEXT+3*, TEXT+4
L TEXT~, TEXT+3
OCK EN+1~, ORD+18*, ORD+19, PRINT+3~, PRINT+34*
OCNT EN~, EN+7*, NDTP+4, PRINT+59*
OI PRINT+2~
OINAM EN~, ORD+13*, ORD+14*, ORD+19, PRINT+2~, PRINT+8*, PRINT+15
OIX PRINT+2~
OK EN+1~
ORD EN~, EN+7*, ORD*, ORD+1, ORD+5, ORD+6, ORD+10, ORD+18, ORD+20, NEXT+2*
, NEXT+9*, NEXT+11, PRINT~, PRINT+5, PRINT+8, PRINT+32, PRINT+33, PRINT+34, PRINT+40, PRINT+41
, PRINT+51, PRINT+53, PRINT+54
PAG EN~, PRINT+6, HDR+1*, HDR+2, HDR+5
PCNT EN~, EN+7*, NDTP+3, PRINT+13*
PNAM EN~, ORD+12*, ORD+14*, ORD+19, PRINT+2~, PRINT+10*, PRINT+11
PRTD EN~, EN+7*, NDTP, NDTP+1, PRINT+59*
PRV PRINT+2~, PRINT+34*, PRINT+47
>> PSOAOI ORD+2
>> PSOAPT DFN, DFN+1
>> PSOED DATE, HDR+7
>> PSOOC ORD+5, ORD+6
>> PSOOI( ORD+2
>> PSOPT( DFN+1
>> PSOSD EN+7, HDR+7
>> PSOSRT ORD+8, ORD+12, ORD+13, ORD+16, ORD+17, NEXT+1, HDR+6
>> PSOST ORD+3, ORD+4
PSSN PRINT+2~, PRINT+10*, PRINT+11
S1 EN~, ORD+15*, ORD+20, NEXT+2*, NEXT+3*, NEXT+4, NEXT+5, NEXT+6, NEXT+7, NEXT+8
, NEXT+9, NEXT+12, NEXT+13
S2 EN~, ORD+15*, ORD+20, NEXT+2*, NEXT+4*, NEXT+5, NEXT+6, NEXT+7, NEXT+8, NEXT+9
, NEXT+12
S3 EN~, ORD+15*, ORD+20, NEXT+2*, NEXT+5*, NEXT+6, NEXT+7, NEXT+8, NEXT+9
S4 EN~, ORD+15*, ORD+20, NEXT+2*, NEXT+6*, NEXT+7, NEXT+8, NEXT+9
S5 EN~, ORD+15*, ORD+20, NEXT+2*, NEXT+7*, NEXT+8, NEXT+9
SCH PRINT+2~, PRINT+19*, PRINT+21, PRINT+22
SP1 EN+1~, EN+4*, DATE+1, NEXT+13, NDTP+2
SP2 EN+1~, EN+4*, NEXT+12
SPF EN+1~, EN+4*, DATE+1, ORD+10*
ST SRT~, SRT+5, SRT+6, SRT+7*, SRT+8
STR PRINT+3~, PRINT+34*, PRINT+36, PRINT+41*, PRINT+42, PRINT+54*, PRINT+55, TEXT~, TEXT+2, TEXT+3
, SRT+3~, SRT+4*, SRT+6
STS EN+1~, ORD+17*, ORD+19
SUB EN+1~
TEXT TEXT~
TEXT( TEXT+3, TEXT+4*
TEXT("" TEXT+1
TXT PRINT+2~, PRINT+36!, PRINT+39!, PRINT+42, PRINT+43, PRINT+52!, PRINT+55
TXT( PRINT+37, PRINT+38, PRINT+44, PRINT+45, PRINT+56, PRINT+57
VADM PRINT+2~
VADM(1 PRINT+10
VADM(2 PRINT+10
VAPA PRINT+2~
VAPA(8 PRINT+12
WORD TEXT+1~, TEXT+3*, TEXT+4
X EN~, PRINT+2~, PRINT+18*, PRINT+19, HDR+1~, HDR+9*, SRT+3~, SRT+6*, SRT+7
XX EN~, ORD+1*, ORD+2, ORD+3, ORD+4, ORD+13, ORD+17, PRINT+2~, PRINT+8*, PRINT+9
, PRINT+17, PRINT+18, PRINT+19, PRINT+20, PRINT+21, PRINT+22, PRINT+23, PRINT+24, PRINT+25, PRINT+26
, PRINT+27, PRINT+28, PRINT+29
Y EN~, ORD+17*, ORD+19
Z PRINT+2~
>> ZTQUEUED CLOSE
>> ZTREQ CLOSE*
Info |  Source |  Call Graph |  Caller Graph |  Entry Points |  External References |  Interaction Calls |  FileMan Files Accessed Via FileMan Db Call |  Global Variables Directly Accessed |  Label References |  Local Variables |  All