PSSPRETR ;BIR/WRT-Pre-transport routine ; 09/02/97 8:48
;;1.0;PHARMACY DATA MANAGEMENT;;9/30/97
; PRE-TRANSPORT ROUTINE
N ROOT,DA,I,X,LINE,TOT
BUILDIT S ROOT=$NA(@XPDGREF@("DATA")),DA=0,I=1,LINE="",TOT=0
F S DA=$O(^PS(51.2,DA)) Q:'DA S X=^(DA,0) I $P(X,"^",2)]"" S @ROOT@(I)=$P(X,"^",1)_"^"_$P(X,"^",2),I=I+1
Q
--- Routine Detail --- with STRUCTURED ROUTINE LISTING ---[H[J[2J[HPSSPRETR 325 printed Dec 13, 2024@02:34:12 Page 2
PSSPRETR ;BIR/WRT-Pre-transport routine ; 09/02/97 8:48
+1 ;;1.0;PHARMACY DATA MANAGEMENT;;9/30/97
+2 ; PRE-TRANSPORT ROUTINE
+3 NEW ROOT,DA,I,X,LINE,TOT
BUILDIT SET ROOT=$NAME(@XPDGREF@("DATA"))
SET DA=0
SET I=1
SET LINE=""
SET TOT=0
+1 FOR
SET DA=$ORDER(^PS(51.2,DA))
if 'DA
QUIT
SET X=^(DA,0)
IF $PIECE(X,"^",2)]""
SET @ROOT@(I)=$PIECE(X,"^",1)_"^"_$PIECE(X,"^",2)
SET I=I+1
+2 QUIT