source: WorldVistAEHR/trunk/r/POLICE_AND_SECURITY-ES/ESP117PT.m@ 1087

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

initial load of WorldVistAEHR

File size: 2.5 KB
Line 
1ESP117PT ;ALB/CJM - ESP *1*17 POST-INSTALL ROUTINE [9/30/96 12:08pm]
2 ;;1.0;POLICE & SECURITY;**17**;Mar 31, 1994
3 ;
4START ;
5 D SSNRPT ;report on duplicate SSN's
6 D SNDXCHG ;fix soundex x-ref on file 910
7 D IDNTFR ;to update multiple 916.05 headers
8 D NEWXREFS ;cross-references files on new x-refs
9 Q
10 ;
11 ;
12SSNRPT ;
13 ;lists duplicate SSN's allowed by faulty input transform
14 ;
15 N SSN,NAME,IEN,TEXT,FLAG
16 D BMES^XPDUTL("...Searching for duplicate SSNs in file #910")
17 S TEXT="IEN SSN",$E(TEXT,46)="NAME" D MES^XPDUTL(TEXT)
18 S TEXT="=== ====",$E(TEXT,46)="===" D MES^XPDUTL(TEXT)
19 S (FLAG,SSN)=""
20 F S SSN=$O(^ESP(910,"SSN",SSN)) Q:SSN="" D
21 .S IEN=$O(^ESP(910,"SSN",SSN,0))
22 .Q:'IEN
23 .I $O(^ESP(910,"SSN",SSN,IEN)) D MES^XPDUTL("") F Q:'IEN D S IEN=$O(^ESP(910,"SSN",SSN,IEN))
24 ..S FLAG=1
25 ..S NAME=$P($G(^ESP(910,IEN,0)),"^")
26 ..S TEXT=IEN,$E(TEXT,10)="",TEXT=TEXT_SSN,$E(TEXT,46)="",TEXT=TEXT_NAME
27 ..D MES^XPDUTL(TEXT)
28 D:FLAG MES^XPDUTL("")
29 D:'FLAG MES^XPDUTL(" **** NO DUPLICATE SSN ENTRIES WERE FOUND **** ")
30 D MES^XPDUTL("...Duplicate entry search Completed.")
31 Q
32 ;
33SNDXCHG ;fixes the SOUN x-ref on file 910
34 ;
35 N DIK,DA
36 D BMES^XPDUTL("...Deleting non-Fileman soundex x-ref on file #910")
37 K ^ESP(910,"SOUN")
38 D MES^XPDUTL("...Creating FileMan soundex x-ref on file #910")
39 S DIK="^ESP(910,",DIK(1)=".01^SOUN" D ENALL^DIK
40 Q
41 ;
42IDNTFR ;
43 ;add I to all time multiple headers in file 916
44 N JRNL
45 S JRNL=0
46 D BMES^XPDUTL("...Adding identifiers to subfile #916.05")
47 F S JRNL=$O(^ESP(916,JRNL)) Q:'JRNL I $D(^ESP(916,JRNL,4,0)) D
48 .S $P(^ESP(916,JRNL,4,0),U,2)="916.05I"
49 Q
50 ;
51NEWXREFS ;
52 ;cross references files on new x-refs added by patch
53 ;
54 N DIK,DA
55 D BMES^XPDUTL("...Creating FileMan ""I"" x-ref on file #910.2")
56 S DIK="^ESP(910.2,",DIK(1)="4.05^I" D ENALL^DIK
57 ;
58 D BMES^XPDUTL("...Creating FileMan ""J"" x-ref on file #910.2")
59 K DIK S DIK="^ESP(910.2,",DIK(1)="5.01^J" D ENALL^DIK
60 ;
61 D BMES^XPDUTL("...Creating FileMan ""J"" x-ref on file #912.09")
62 K DA
63 S DA(1)=0
64 F S DA(1)=$O(^ESP(912,DA(1))) Q:'DA(1) D
65 .Q:'$D(^ESP(912,DA(1),80))
66 .S DA="",DIK="^ESP(912,"_DA(1)_",80,",DIK(1)=".11^J" D ENALL^DIK
67 ;
68 D BMES^XPDUTL("...Creating FileMan ""D"" x-ref on file #910.85")
69 K DA
70 S DA(1)=0
71 F S DA(1)=$O(^ESP(910.8,DA(1))) Q:'DA(1) D
72 .Q:'$D(^ESP(910.8,DA(1),5))
73 .S DA="",DIK="^ESP(910.8,"_DA(1)_",5,",DIK(1)=".03^D" D ENALL^DIK
74 Q
75 ;
76SSNDUP ; entry point to run ssn duplicate report.
77 N POP
78 S %ZIS="QM" D ^%ZIS Q:POP
79 I $D(IO("Q")) D Q
80 . S ZTRTN="SSNRPT^ESP117PT",ZTDESC="DUP SSN REPORT ON #910"
81 . D ^%ZTLOAD
82 . D HOME^%ZIS K IO("Q") Q
83 U IO
84 D SSNRPT
85 D ^%ZISC
86 Q
Note: See TracBrowser for help on using the repository browser.