added to C0XF2N ADDINN -add if not null

This commit is contained in:
george 2012-04-05 15:13:33 +00:00
parent af30ebada4
commit 3a42c126a7
1 changed files with 13 additions and 0 deletions

View File

@ -516,6 +516,19 @@ IENOFA(ZOUTARY,INARY,FARY) ; RESOLVE STRINGS TO IEN IN STRINGS FILE
. S ZOUTARY("IEN",ZI,ZIEN)=""
Q
;
ADDINN(ZG,ZS,ZARY) ; ADD IF NOT NULL
; ZG IS THE GRAPH NAME, PASSED BY VALUE
; ZS IS THE SUBJECT, PASSED BY VALUE
; ZARY IS AN ARRAY, PASSED BY REFERENCE OF THE PREDICATE AND OBJECT
; FORMAT IS ZARY(PRED)=OBJ
N ZI S ZI=""
F S ZI=$O(ZARY(ZI)) Q:ZI="" D ;
. I ZARY(ZI)'="" D ;
. . D ADD^C0XF2N(ZG,ZS,ZI,ZARY(ZI))
. . W !,"ADDING",ZI," ",ZARY(ZI)
;ZWR ZARY
Q
;
BULKLOAD(ZBFDA) ; BULK LOADER FOR LOADING TRIPLES INTO FILE 172.101
; USING GLOBAL SETS INSTEAD OF UPDATE^DIE
; QUITS IF FILE IS NOT 172.101