I have the below XML that I have stubbed out in for import to AWS S3. This will then be sent to a vendor from S3.
My question is around the recordtype "02". This will be used for dependent information and I would like a new "02" recordtype for each dependent with the two fields I have outlined. I currently have an array for Dependents and am using one-to-many on the AWS import/transfer. The most "02" segments I would need is 8, but my issue is I dont want to hardcode these when there could be only 1 or 2 dependents.
Is there a way to create/add an 02 segment for each dependent dynamically, or would I need to add 8 "02" segments to my XML and then just send blank "02" segments if (for example) there were only 2 dependents?
000
{{batch_of_records.0.record._PARENT.PrimaryMember.FirstName}} {{batch_of_records.0.record._PARENT.PrimaryMember.LastName}}
{{batch_of_records.0.record._PARENT.PrimaryMember.StreetAddress}}
{{batch_of_records.0.record._PARENT.PrimaryMember.City}}
{{batch_of_records.0.record._PARENT.PrimaryMember.State}}
{{batch_of_records.0.record._PARENT.PrimaryMember.ZipCode}}
{{batch_of_records.0.record._PARENT.ZelisHardCodedFields.RecipientCode}}
000
{{batch_of_records.0.record._PARENT.ZelisHardCodedFields.cRIcode}}
01
{{batch_of_records.0.record._PARENT.ZelisHardCodedFields.cIssuanceCode}}
{{batch_of_records.0.record.Employer}}
11778
M0005866
{{batch_of_records.0.record.FirstName}} {{batch_of_records.0.record.LastName}}
{{batch_of_records.0.record.FirstName}}
{{batch_of_records.0.record.LastName}}
{{batch_of_records.0.record.MiddleName}}
{{batch_of_records.0.record.MemberId}}
{{batch_of_records.0.record.Birthdate}}
Z323
{{batch_of_records.0.record.DependentFirstName}} {{batch_of_records.0.record.DependentLastName}}
{{batch_of_records.0.record.DependentPersonCode}}
{{batch_of_records.0.record.DependentFirstName}} {{batch_of_records.0.record.DependentLastName}}
{{batch_of_records.0.record.DependentPersonCode}}
{{batch_of_records.0.record._PARENT.ZelisHardCodedFields.PlanType}}