source: Scheduling/trunk/m/BSDX03.m@ 1675

Last change on this file since 1675 was 1625, checked in by Tariq Hamkari, 11 years ago

Ayman Ghaith : adding the correct routines which not has the transactions.

File size: 1.4 KB
Line 
1BSDX03 ; IHS/OIT/HMW - WINDOWS SCHEDULING RPCS ; 4/28/11 10:14am
2 ;;1.7;BSDX;;Jun 01, 2013;Build 24
3 ;Licensed under LGPL
4 ;
5 ;
6 Q
7 ;
8XR2S(BSDXDA) ;EP
9 ;XR2 is the ARSRC xref for the
10 ;RESOURCE field of the BSDX APPOINTMENT file
11 ;Format is ^BSDXAPPT("ARSRC",RESOURCEID,STARTTIME,APPTID)
12 Q:'$D(^BSDXAPPT(BSDXDA,0))
13 N BSDXNOD,BSDXAPPID,BSDXRSID,BSDXS
14 S BSDXNOD=^BSDXAPPT(BSDXDA,0)
15 S BSDXAPPID=BSDXDA
16 S BSDXRSID=$P(BSDXNOD,U,7)
17 Q:'+BSDXAPPID>0
18 Q:'+BSDXRSID>0
19 S BSDXS=$P(BSDXNOD,U)
20 Q:'+BSDXS
21 S ^BSDXAPPT("ARSRC",BSDXRSID,BSDXS,BSDXAPPID)=""
22 Q
23 ;
24XR2K(BSDXA) ;EP
25 Q:'$D(^BSDXAPPT(BSDXA,0))
26 N BSDXNOD,BSDXAPPID,BSDXRSID,BSDXS
27 S BSDXNOD=^BSDXAPPT(BSDXA,0)
28 S BSDXAPPID=BSDXA
29 S BSDXRSID=$P(BSDXNOD,U,7)
30 S BSDXS=$P(BSDXNOD,U)
31 Q:'+BSDXAPPID>0
32 Q:'+BSDXRSID>0
33 Q:'+BSDXS>0
34 K ^BSDXAPPT("ARSRC",BSDXRSID,BSDXS,BSDXAPPID)
35 Q
36XR4S(BSDXDA) ;EP
37 ;XR4 is the ARSCT xref for the
38 ;STARTTIME field of the BSDX ACCESS BLOCK file
39 ;Format is ^BSDXAB("ARSCT",RESOURCEID,STARTTIME,DA)
40 Q:'$D(^BSDXAB(BSDXDA,0))
41 N BSDXNOD,BSDXR,BSDXS
42 S BSDXNOD=^BSDXAB(BSDXDA,0)
43 S BSDXR=$P(BSDXNOD,U)
44 S BSDXS=$P(BSDXNOD,U,2)
45 Q:'+BSDXR>0
46 Q:'+BSDXS>0
47 S ^BSDXAB("ARSCT",BSDXR,BSDXS,BSDXDA)=""
48 Q
49 ;
50XR4K(BSDXDA) ;EP
51 Q:'$D(^BSDXAB(BSDXDA,0))
52 N BSDXNOD,BSDXR,BSDXS
53 S BSDXNOD=^BSDXAB(BSDXDA,0)
54 S BSDXR=$P(BSDXNOD,U)
55 S BSDXS=$P(BSDXNOD,U,2)
56 Q:'+BSDXR>0
57 Q:'+BSDXS>0
58 K ^BSDXAB("ARSCT",BSDXR,BSDXS,BSDXDA)
59 Q
Note: See TracBrowser for help on using the repository browser.