AnsweredAssumed Answered

Problem combining XML documents

Question asked by dlarkin040873 on Jul 15, 2017
Latest reply on Jul 26, 2017 by aaron.de.rybel821561

I'm struggling with this simple task.  Any help would be greatly appreciated.

 

My Start shape (Connector) returns 22 documents, passes them to a Map shape and that feeds a Data Process shape.

 

Based on what I’ve read / researched this should be pretty basic.  But I am obviously missing something.  I either get output that more or less mirrors the input (i.e. no files are combined) OR if I add a Flow Control shape between the Map and the Data Process I get all 22 documents combined into a single document. 

 

 

Here is what is coming into my Map:

DBSTART|b05393b7-b4cf-4779-87e5-40a651e19ba1|2|@|BEGIN|2|@|OUT_START|3|@|2017-07-01 11:05:11.803|^|ZZZ-111111|^|LAB FRONT-END|^|NO DATE OF BIRTH|^|Issue|^|11X22Y33Z|^|JOE|^|KING|#|2017-07-01 11:05:11.803|^|ZZZ-111111|^|QC/REQ REVIEW|^|INSURANCE INFO INCOMPLETE|^|Issue|^|11X22Y33Z|^|JOE|^|KING|#|2017-07-01 11:05:11.803|^|ZZZ-111111|^|QC/REQ REVIEW|^|PATIENT DEMOGRAPHICS|^|Issue|^|11X22Y33Z|^|JOE|^|KING|#||#|OUT_END|3|@|END|2|@|DBEND|b05393b7-b4cf-4779-87e5-40a651e19ba1|2|@|

 

My Map:

 

Going into my Data Process is:

 

Shape Source Data 1:

<?xml version='1.0' encoding='UTF-8'?>

<PP_Record>

  <All>

    <Accession_Count>3</Accession_Count>

    <Data>

      <Created_Date>2017-07-01 11:05:11.803</Created_Date>

      <Accession_Number>ZZZ-111111</Accession_Number>

      <Section>QC/REQ REVIEW</Section>

      <Field>INSURANCE INFO INCOMPLETE</Field>

      <Value>Issue</Value>

      <NPI>11X22Y33Z</NPI>

      <First_Name>JOE</First_Name>

      <Last_Name>KING</Last_Name>

    </Data>

  </All>

</PP_Record>

 

Shape Source Data 2:

<?xml version='1.0' encoding='UTF-8'?>

<PP_Record>

  <All>

    <Accession_Count>3</Accession_Count>

    <Data>

      <Created_Date>2017-07-01 11:05:11.803</Created_Date>

      <Accession_Number>ZZZ-111111</Accession_Number>

      <Section>QC/REQ REVIEW</Section>

      <Field>PATIENT DEMOGRAPHICS</Field>

      <Value>Issue</Value>

      <NPI>11X22Y33Z</NPI>

      <First_Name>JOE</First_Name>

      <Last_Name>KING</Last_Name>

    </Data>

  </All>

</PP_Record>

 

Shape Source Data 3:

<?xml version='1.0' encoding='UTF-8'?>

<PP_Record>

  <All>

    <Accession_Count>3</Accession_Count>

    <Data>

      <Created_Date>2017-07-01 11:05:11.803</Created_Date>

      <Accession_Number>ZZZ-111111</Accession_Number>

      <Section>LAB FRONT-END</Section>

      <Field>NO DATE OF BIRTH</Field>

      <Value>Issue</Value>

      <NPI>11X22Y33Z</NPI>

      <First_Name>JOE</First_Name>

      <Last_Name>KING</Last_Name>

    </Data>

  </All>

</PP_Record>

 

 

I need the results to look like this:

 <PP_Record>

  <All>

    <Accession_Count>3</Accession_Count>

    <Data>

      <Created_Date>2017-07-01 11:05:11.803</Created_Date>

      <Accession_Number>ZZZ-111111</Accession_Number>

      <Section>QC/REQ REVIEW</Section>

      <Field>INSURANCE INFO INCOMPLETE</Field>

      <Value>Issue</Value>

      <NPI>11X22Y33Z</NPI>

      <First_Name>JOE</First_Name>

      <Last_Name>KING</Last_Name>

    </Data>

    <Data>

      <Created_Date>2017-07-01 11:05:11.803</Created_Date>

      <Accession_Number>ZZZ-111111</Accession_Number>

      <Section>QC/REQ REVIEW</Section>

      <Field>PATIENT DEMOGRAPHICS</Field>

      <Value>Issue</Value>

      <NPI>11X22Y33Z</NPI>

      <First_Name>JOE</First_Name>

      <Last_Name>KING</Last_Name>

    </Data>

    <Data>

      <Created_Date>2017-07-01 11:05:11.803</Created_Date>

      <Accession_Number>ZZZ-111111</Accession_Number>

      <Section>LAB FRONT-END</Section>

      <Field>NO DATE OF BIRTH</Field>

      <Value>Issue</Value>

      <NPI>11X22Y33Z</NPI>

      <First_Name>JOE</First_Name>

      <Last_Name>KING</Last_Name>

    </Data>

  </All>

</PP_Record>

Outcomes