source: FOIAVistA/tag/r/NOIS-FSC/FSCQSN.m@ 812

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

initial load of FOIAVistA 6/30/08 version

File size: 3.1 KB
Line 
1FSCQSN ;SLC/STAFF-NOIS Query Search Nonindexed ;8/8/98 21:28
2 ;;1.1;NOIS;;Sep 06, 1998
3 ;
4EX ; from FSCQS
5 I CODE["7100.6" D PEX Q
6 I LIST=1!(LIST=0) D Q
7 .S NODE=+$P(CODE,";"),PIECE=$P(CODE,";",2)
8 .S CALL=0 F S CALL=$O(^TMP("FSC USELIST",$J,CALL)) Q:CALL<1 D
9 ..I $L($P($G(^FSCD("CALL",CALL,NODE)),U,PIECE)) X ACTION
10 I LIST="" D Q
11 .S NODE=+$P(CODE,";"),PIECE=$P(CODE,";",2)
12 .S CALL=0 F S CALL=$O(^FSCD("CALL",CALL)) Q:CALL<1 D
13 ..I $L($P($G(^FSCD("CALL",CALL,NODE)),U,PIECE)) X ACTION
14 Q
15NEX ; from FSCQS
16 I CODE["7100.6" D PNEX Q
17 I LIST=1!(LIST=0) D Q
18 .S NODE=+$P(CODE,";"),PIECE=$P(CODE,";",2)
19 .S CALL=0 F S CALL=$O(^TMP("FSC USELIST",$J,CALL)) Q:CALL<1 D
20 ..I '$L($P($G(^FSCD("CALL",CALL,NODE)),U,PIECE)) X ACTION
21 I LIST="" D Q
22 .S NODE=+$P(CODE,";"),PIECE=$P(CODE,";",2)
23 .S CALL=0 F S CALL=$O(^FSCD("CALL",CALL)) Q:CALL<1 D
24 ..I '$L($P($G(^FSCD("CALL",CALL,NODE)),U,PIECE)) X ACTION
25 Q
26OTHER ; from FSCQS
27 I CODE["7100.6" D POTHER Q
28 S NODE=+$P(CODE,";"),PIECE=$P(CODE,";",2),CHECK="CVALUE"_COND_$S(VALUE=+VALUE:VALUE,1:""""_$$UP^XLFSTR(VALUE)_"""")
29 I LIST=1!(LIST=0) D Q
30 .S CALL=0 F S CALL=$O(^TMP("FSC USELIST",$J,CALL)) Q:CALL<1 D
31 ..S CVALUE=$$UP^XLFSTR($P($G(^FSCD("CALL",CALL,NODE)),U,PIECE)) I $L(CVALUE),@CHECK X ACTION
32 I LIST="" D Q
33 .S CALL=0 F S CALL=$O(^FSCD("CALL",CALL)) Q:CALL<1 D
34 ..S CVALUE=$$UP^XLFSTR($P($G(^FSCD("CALL",CALL,NODE)),U,PIECE)) I $L(CVALUE),@CHECK X ACTION
35 Q
36 ;
37PEX ;
38 N IEN
39 S CODE=$P(CODE,",",2)
40 I LIST=1!(LIST=0) D Q
41 .S NODE=+$P(CODE,";"),PIECE=$P(CODE,";",2)
42 .S CALL=0 F S CALL=$O(^TMP("FSC USELIST",$J,CALL)) Q:CALL<1 D
43 ..S IEN=+$G(^FSCD("CALL USER","AUC",DUZ,CALL)) I 'IEN Q
44 ..I $L($P($G(^FSCD("CALL USER",IEN,NODE)),U,PIECE)) X ACTION
45 I LIST="" D Q
46 .S NODE=+$P(CODE,";"),PIECE=$P(CODE,";",2)
47 .S CALL=0 F S CALL=$O(^FSCD("CALL USER","AUC",DUZ,CALL)) Q:CALL<1 D
48 ..S IEN=+$G(^FSCD("CALL USER","AUC",DUZ,CALL)) I 'IEN Q
49 ..I $L($P($G(^FSCD("CALL USER",IEN,NODE)),U,PIECE)) X ACTION
50 Q
51PNEX ;
52 N IEN
53 S CODE=$P(CODE,",",2)
54 I LIST=1!(LIST=0) D Q
55 .S NODE=+$P(CODE,";"),PIECE=$P(CODE,";",2)
56 .S CALL=0 F S CALL=$O(^TMP("FSC USELIST",$J,CALL)) Q:CALL<1 D
57 ..S IEN=+$G(^FSCD("CALL USER","AUC",DUZ,CALL))
58 ..I '$L($P($G(^FSCD("CALL USER",IEN,NODE)),U,PIECE)) X ACTION
59 I LIST="" D Q
60 .S NODE=+$P(CODE,";"),PIECE=$P(CODE,";",2)
61 .S CALL=0 F S CALL=$O(^FSCD("CALL USER","AUC",DUZ,CALL)) Q:CALL<1 D ; *** only checking calls in call user file, not all calls
62 ..S IEN=+$G(^FSCD("CALL USER","AUC",DUZ,CALL))
63 ..I '$L($P($G(^FSCD("CALL USER",IEN,NODE)),U,PIECE)) X ACTION
64 Q
65POTHER ;
66 N IEN
67 S CODE=$P(CODE,",",2)
68 S NODE=+$P(CODE,";"),PIECE=$P(CODE,";",2),CHECK="CVALUE"_COND_$S(VALUE=+VALUE:VALUE,1:""""_$$UP^XLFSTR(VALUE)_"""")
69 I LIST=1!(LIST=0) D Q
70 .S CALL=0 F S CALL=$O(^TMP("FSC USELIST",$J,CALL)) Q:CALL<1 D
71 ..S IEN=+$G(^FSCD("CALL USER","AUC",DUZ,CALL)) I 'IEN Q
72 ..S CVALUE=$$UP^XLFSTR($P($G(^FSCD("CALL USER",IEN,NODE)),U,PIECE)) I $L(CVALUE),@CHECK X ACTION
73 I LIST="" D Q
74 .S CALL=0 F S CALL=$O(^FSCD("CALL USER","AUC",DUZ,CALL)) Q:CALL<1 D
75 ..S IEN=+$G(^FSCD("CALL USER","AUC",DUZ,CALL)) I 'IEN Q
76 ..S CVALUE=$$UP^XLFSTR($P($G(^FSCD("CALL USER",IEN,NODE)),U,PIECE)) I $L(CVALUE),@CHECK X ACTION
77 Q
Note: See TracBrowser for help on using the repository browser.