source: WorldVistAEHR/trunk/r/PHARMACY_DATA_MANAGEMENT-PSS/PSSSYN.m@ 724

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

initial load of WorldVistAEHR

File size: 803 bytes
Line 
1PSSSYN ;BIR/WRT-ADD SYNONYMS FROM 50 TO ORDERABLE ITEM FILE ; 09/02/97 8:56
2 ;;1.0;PHARMACY DATA MANAGEMENT;;9/30/97
3 D LOOP,DEX
4 Q
5LOOP F NUM=0:0 S NUM=$O(^PSDRUG(NUM)) Q:'NUM I $D(^PSDRUG(NUM,2)) S POI=$P(^PSDRUG(NUM,2),"^",1) I POI]"",$D(^PS(50.7,POI,0)) D LOOP1
6 Q
7LOOP1 I $D(^PSDRUG(NUM,1,0)) F NUMB=0:0 S NUMB=$O(^PSDRUG(NUM,1,NUMB)) Q:'NUMB S IUSE=$P(^PSDRUG(NUM,1,NUMB,0),"^",3) I IUSE=0!(IUSE="") S SYNO=$P(^PSDRUG(NUM,1,NUMB,0),"^",1) D CHEK
8 Q
9CHEK I '$D(^PS(50.7,"C",SYNO,POI)) D ADD
10 Q
11ADD S DA(1)=POI,DIC="^PS(50.7,"_POI_",2,",X=SYNO,DIC(0)="L",DIC("P")=$P(^DD(50.7,2,0),"^",2),DLAYGO=50.72 D ^DIC
12 Q
13DEX K ^PS(50.7,"C") F IEN=0:0 S IEN=$O(^PS(50.7,IEN)) Q:'IEN F IEN1=0:0 S IEN1=$O(^PS(50.7,IEN,2,IEN1)) Q:'IEN1 S SYN=$P(^PS(50.7,IEN,2,IEN1,0),"^",1),^PS(50.7,"C",SYN,IEN,IEN1)=""
14 Q
Note: See TracBrowser for help on using the repository browser.