source: WorldVistAEHR/trunk/r/HINQ-DVB--DVBA--DVBE--DVBC/DVBHQR3.m@ 1046

Last change on this file since 1046 was 613, checked in by George Lilly, 15 years ago

initial load of WorldVistAEHR

File size: 1.4 KB
Line 
1DVBHQR3 ;ISC-ALBANY/PKE-parse Birls response ; 8/19/87 06:44 ;
2 ;;V4.0;HINQ;;03/25/92
3 ;abbreviated name, number parser
4 G EN
5RON S LP=(L\246)+1,L2=L#245 S:L2=0 L2=245 S L3=L1-(245-L2) ;maybe +1
6 I $D(X(LP)) S X=$E(X(LP),L2,L2+L1-1) I $L(X)<L1,$D(X(LP+1)) S X=X_$E(X(LP+1),1,L3) Q
7 Q
8FOLDER Q:'+DVBFL(I) S Z=0,Z=$O(^DIC(4,"D",+DVBFL(I),Z)) I Z,$D(^DIC(4,Z,0)) S DVBFL(I)=Z_" - "_$P(^(0),U) Q
9 Q
10BOS S Z=DVBBOS(I),DVBBOS(I)=$S(Z="A ":"ARMY",Z="AF ":"AFOR",1:Z) Q
11 ;
12EN S L=1,L1=27 D RON S DVBABREV=$E(X,5) D:DVBABREV="N" NAME D:DVBABREV="M" NUMBER Q
13 ;
14NAME S DFN=+$E(X,8,21),DVBLEN=$E(X,22,25),DVBRECN=+$E(X,26,27) I 'DVBRECN K DVBRECN Q
15 ;
16 S L=28,L1=53 D RON
17 F I=1:1:DVBRECN D PARSE
18 Q
19PARSE S LF=$F(X,"@"),X=$E(X,1,LF-1)
20 I LF,$L(X)
21 E Q
22 S DVBCN(I)=$E(X,1,9),DVBSSN(I)=$E(X,10,18),DVBSN(I)=$E(X,19,27),DVBPAYN(I)=$E(X,28,29),DVBDOB(I)=$E(X,30,33),DVBDOD(I)=$E(X,34,37)
23 S DVBEOD(I)=$E(X,38,41),DVBRAD(I)=$E(X,42,45),DVBBOS(I)=$E(X,46,49),DVBFL(I)=$E(X,50,52),L=L+LF-1 D RON,FOLDER,BOS Q
24 ;
25NUMBER S DFN=+$E(X,8,21),DVBLEN=$E(X,22,25),DVBRECN=+$E(X,26,27) I 'DVBRECN K DVBRECN Q
26 S L=28,L1=67 D RON
27 F I=1:1:DVBRECN D PARSE1
28 Q
29PARSE1 S LF=$F(X,"@"),X=$E(X,1,LF-1)
30 I LF,$L(X)
31 E Q
32 S DVBNAM(I)=$E(X,1,36),DVBCN(I)=$E(X,37,45),DVBPAYN(I)=$E(X,46,47),DVBFL(I)=$E(X,48,50),DVBEOD(I)=$E(X,51,54),DVBRAD(I)=$E(X,55,58),DVBDOB(I)=$E(X,59,62),DVBDOD(I)=$E(X,63,66),L=L+LF-1 D RON,FOLDER Q
33 Q
Note: See TracBrowser for help on using the repository browser.