HL7 append Segment

176 views Asked by At

To avoid using EVNgrp due to schema issues, I have this code that is meant to append PID and PD1 segment to ADR^A19. For some reason it is not doing so. Any help please?

If $Length(source.Primary.PID) {
  Set oSeg=##class(EnsLib.HL7.Segment).ImportFromString(source.Primary.PID)
     Do target.AppendSegment(oSeg)
  }
              If $Length(source.Primary.PD1) {
          Set oSeg=##class(EnsLib.HL7.Segment).ImportFromString(source.Primary.PD1)
               Do target.AppendSegment(oSeg)
 }
1

There are 1 answers

0
softgi On

I found out that the issue was caused by environmental problem which was resolved and the code is now working fine. Thank you all for your help.