1 | SCDXSUP2 ;ALB/JRP - PURGE ERROR FILE;22-APR-97 ; 12/20/01 4:49pm
|
---|
2 | ;;5.3;Scheduling;**121,247**;AUG 13, 1993
|
---|
3 | ;
|
---|
4 | PRGCO ;Purge TRANSMITTED OUTPATIENT ENCOUNTER ERROR file (#409.75) of
|
---|
5 | ; rejections for encounters that can not be transmitted due to
|
---|
6 | ; NPCD Database Close-Out
|
---|
7 | ;
|
---|
8 | ;Input : None
|
---|
9 | ;Output : None
|
---|
10 | ;
|
---|
11 | ;Declare variables
|
---|
12 | N ZTRTN,ZTDESC,ZTIO,ZTDTH,ZTSK,DIR,Y,X,DTOUT,DUOUT,DIRUT
|
---|
13 | ;'Are you sure' prompt
|
---|
14 | S DIR("A",1)=" "
|
---|
15 | S DIR("A",2)="This option will purge entries in the TRANSMITTED OUTPATIENT"
|
---|
16 | S DIR("A",3)="ENCOUNTER ERROR file (#409.75) of rejections for encounters that"
|
---|
17 | S DIR("A",4)="can not be transmitted due to close-out of the National Patient"
|
---|
18 | S DIR("A",5)="Care Database for database credit."
|
---|
19 | S DIR("A",6)=" "
|
---|
20 | S DIR("A")="Ok to continue"
|
---|
21 | S DIR("B")="NO"
|
---|
22 | S DIR(0)="Y"
|
---|
23 | D ^DIR
|
---|
24 | Q:('Y)
|
---|
25 | ;Task (no device needed)
|
---|
26 | S ZTRTN="PRGCOT^SCDXSUP2"
|
---|
27 | S ZTDESC="Purge file #409.75 of encounters that won't get database credit"
|
---|
28 | S ZTIO=""
|
---|
29 | S ZTDTH=""
|
---|
30 | D ^%ZTLOAD
|
---|
31 | W:($G(ZTSK)) !!,"Scheduled as task number ",ZTSK
|
---|
32 | W:('$G(ZTSK)) !!,"** Unable to schedule correctly **"
|
---|
33 | Q
|
---|
34 | ;
|
---|
35 | PRGCOT ;Task entry point (self contained)
|
---|
36 | ;Declare variables
|
---|
37 | N XMITPTR
|
---|
38 | ;Loop through 'B' x-ref
|
---|
39 | S XMITPTR=0
|
---|
40 | F S XMITPTR=+$O(^SD(409.75,"B",XMITPTR)) Q:('XMITPTR) D Q:($$S^%ZTLOAD())
|
---|
41 | .;Determine if encounter can be transmitted for database credit
|
---|
42 | .Q:+$$XMIT4DBC^SCDXFU04(XMITPTR)<4 ;SD*5.3*247
|
---|
43 | .;Won't received database credit - delete all errors for encounter
|
---|
44 | .D DELAERR^SCDXFU02(XMITPTR)
|
---|
45 | ;Done
|
---|
46 | S:($D(ZTQUEUED)) ZTREQ="@"
|
---|
47 | Q
|
---|