Skip to Content
0
Apr 19 at 04:57 PM

Handling missing child nodes

66 Views

Hello Friends

I'm building a process flow where I receive demographic data from Workday and after some mapping/transformation I will send it over to a travel system.

The file I receive from Workday is XML and has child nodes for home and work address. I'm mapping their elements to a flat structure - ultimately a csv.

My challenge is - if there is no home address maintained in Workday it does not send the child node (Primary_Home_Address_Group) and its elements. I'm trying to figure out how to test whether I have an element. If I do I'll pass its value, if I don't then I'll pass an empty string. Without the the child node (Primary_Home_Address_Group) my logic does not seem to work when testing for the presence of its elements.

See below. Thank you!! /Greg

Mapping structure:

image.png

Home_street_address logic below does not work if parent group Primary_Home_Address_Group is not sent.

image.png

Attachments

image.png (53.2 kB)
image.png (18.0 kB)