Mulitple Flat Files to One Hl7 message

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Mulitple Flat Files to One Hl7 message

  • Creator
    Topic
  • #51630
    Gary Atkinson
    Participant

      Has anyone taken multiple flat files and created a single Hl7 per unique entry in the flat files?  So, there is one field in each flat file and that is unique for each row of data and links to the other flat files.  One file may have insurance data and the other patient demographics.  I need to take those files and create a single Hl7 for each row of data.  I have done this before with a single flat file, but never with multiple.  Any ideas would be great!!

    Viewing 0 reply threads
    • Author
      Replies
      • #71033
        Chris Williams
        Participant

          Gary,

          You want to make sure both files are sorted in the same order. Read a record from File 1, read any corresponding records from File 2, write the HL7, and go back to read the next record from File 1. You will want Your code to allow for the possibility of no matching records in File 2. It’s the old sort/merge process from days gone bye, when everything was done on big tape drives before disk storage was practical.

          Cheers.

          Chris

      Viewing 0 reply threads
      • The forum ‘Cloverleaf’ is closed to new topics and replies.