Hello,
This is my schema:
<?xml version="1.0" encoding="UTF-8"?>
<xsd:schema targetNamespace="http://pac.bluecross.ca/Common/Types" xmlns="http://pac.bluecross.ca/Common/Types" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:element name="Enrollment" type="Enrollment" nillable="true"/>
<xsd:simpleType name="DependentCategoryCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Child"/>
<xsd:enumeration value="Spouse"/>
<xsd:enumeration value="Insured"/>
<xsd:enumeration value="Dependent"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="ProvinceCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="AB"/>
<xsd:enumeration value="BC"/>
<xsd:enumeration value="MB"/>
<xsd:enumeration value="NB"/>
<xsd:enumeration value="NL"/>
<xsd:enumeration value="NT"/>
<xsd:enumeration value="NS"/>
<xsd:enumeration value="ON"/>
<xsd:enumeration value="PE"/>
<xsd:enumeration value="QC"/>
<xsd:enumeration value="SK"/>
<xsd:enumeration value="YT"/>
<xsd:enumeration value="NU"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="ReapplicationReasonCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Exception"/>
<xsd:enumeration value="Invalid"/>
<xsd:enumeration value="Valid"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="SexCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Male"/>
<xsd:enumeration value="Female"/>
<xsd:enumeration value="NotApplicable"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="CancelReasonCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="LaidOff"/>
<xsd:enumeration value="Retired"/>
<xsd:enumeration value="Divorced"/>
<xsd:enumeration value="Separated"/>
<xsd:enumeration value="NoLongerEligibleForCoverage"/>
<xsd:enumeration value="MaternityLeave"/>
<xsd:enumeration value="LeaveOfAbsense"/>
<xsd:enumeration value="OnDisability"/>
<xsd:enumeration value="PensionExpired"/>
<xsd:enumeration value="StrikeOrLockout"/>
<xsd:enumeration value="TransferredToAnotherCarrier"/>
<xsd:enumeration value="WaivedBenefitsNoReason"/>
<xsd:enumeration value="WaivedBenefitsSpousalCoverage"/>
<xsd:enumeration value="LeftCompany"/>
<xsd:enumeration value="DisContinuedCoverage"/>
<xsd:enumeration value="NoProvincialMedicalPlan"/>
<xsd:enumeration value="Transferred"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="FrequencyCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Annual"/>
<xsd:enumeration value="BiMonthly"/>
<xsd:enumeration value="BiWeekly"/>
<xsd:enumeration value="Hourly"/>
<xsd:enumeration value="Monthly"/>
<xsd:enumeration value="Quarterly"/>
<xsd:enumeration value="SemiAnnually"/>
<xsd:enumeration value="SemiMonthly"/>
<xsd:enumeration value="Weekly"/>
<xsd:enumeration value="LifeTime"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="EmploymentTypeCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Director"/>
<xsd:enumeration value="FullTimeSalary"/>
<xsd:enumeration value="FullTimeHourly"/>
<xsd:enumeration value="PartTimeSalary"/>
<xsd:enumeration value="PartTimeHourly"/>
<xsd:enumeration value="OwnerOperator"/>
<xsd:enumeration value="Retired"/>
<xsd:enumeration value="Seasonal"/>
<xsd:enumeration value="Casual"/>
<xsd:enumeration value="Client"/>
<xsd:enumeration value="Consultant"/>
<xsd:enumeration value="Contract"/>
<xsd:enumeration value="ElectedOfficial"/>
<xsd:enumeration value="JobShare"/>
<xsd:enumeration value="Temporary"/>
<xsd:enumeration value="Volunteer"/>
<xsd:enumeration value="MSDRecipientnotEE"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="DependentSubCategoryCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Student"/>
<xsd:enumeration value="Minor"/>
<xsd:enumeration value="CommonLaw"/>
<xsd:enumeration value="Married"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="LanguageCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="ENG"/>
<xsd:enumeration value="FRA"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="IncomeTypeCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Salary"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="LineOfBusinessCategoryCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Health"/>
<xsd:enumeration value="Dental"/>
<xsd:enumeration value="Life"/>
<xsd:enumeration value="AccidentalDeathAndDismemberment"/>
<xsd:enumeration value="Disability"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="CorrespondenceMethodCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Mail"/>
<xsd:enumeration value="Telephone"/>
<xsd:enumeration value="Email"/>
<xsd:enumeration value="FTP"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="CorrespondenceTypeCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Home"/>
<xsd:enumeration value="Office"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="FamilyCategoryCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Single"/>
<xsd:enumeration value="Family"/>
<xsd:enumeration value="Couple"/>
<xsd:enumeration value="NotApplicable"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:simpleType name="CoveredLifeStatusCodes">
<xsd:restriction base="xsd:string">
<xsd:enumeration value="Inforce"/>
<xsd:enumeration value="Terminated"/>
</xsd:restriction>
</xsd:simpleType>
<xsd:complexType name="EmploymentRecord">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="EffectiveDate" type="xsd:dateTime" minOccurs="0" form="qualified"/>
<xsd:element name="Frequency" type="FrequencyCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="HoursWorked" type="xsd:decimal" minOccurs="0" form="qualified"/>
<xsd:element name="SalaryAmount" type="xsd:decimal" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Type" type="EmploymentTypeCodes" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="Policy">
<xsd:complexContent>
<xsd:extension base="Structurable">
<xsd:sequence>
<xsd:element name="Code" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Certificates" type="ArrayOfCertificate" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="ArrayOfCertificate">
<xsd:sequence>
<xsd:element name="Certificate" type="Certificate" minOccurs="0" maxOccurs="unbounded" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="ContactInformation">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="CorrespondenceMethod" type="CorrespondenceMethodCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="CorrespondenceNote" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="CorrespondenceType" type="CorrespondenceTypeCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Data" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="RegionalAdministrativeInformation">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="Country" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="ProvinceOfBilling" type="ProvinceCodes" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="ArrayOfDivision">
<xsd:sequence>
<xsd:element name="Division" type="Division" minOccurs="0" maxOccurs="unbounded" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="Person">
<xsd:complexContent>
<xsd:extension base="Client">
<xsd:sequence>
<xsd:element name="DateOfBirth" type="xsd:dateTime" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="FirstName" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="LastName" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="MaidenName" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="MiddleName" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="PreferredName" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="***" type="SexCodes" minOccurs="0" form="qualified"/>
<xsd:element name="Suffix" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="Structurable">
<xsd:complexContent>
<xsd:extension base="BusinessObject"/>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="Section">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="Code" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="Plan">
<xsd:complexContent>
<xsd:extension base="Structurable">
<xsd:sequence>
<xsd:element name="Code" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="EffectiveDate" type="xsd:dateTime" minOccurs="0" form="qualified"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="Client">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="Contacts" type="ArrayOfContactInformation" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="DefaultAddress" type="Address" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="DefaultEmail" type="ContactInformation" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="DefaultPhone" type="ContactInformation" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="PreferredContact" type="CorrespondenceMethodCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="PreferredLanguage" type="LanguageCodes" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="BusinessObject">
<xsd:sequence/>
</xsd:complexType>
<xsd:complexType name="ArrayOfBenefitDecline">
<xsd:sequence>
<xsd:element name="BenefitDecline" type="BenefitDecline" minOccurs="0" maxOccurs="unbounded" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="HealthCareSpendingAccountInformation">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="AllocationAmount" type="xsd:decimal" minOccurs="0" form="qualified"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="ArrayOfPolicy">
<xsd:sequence>
<xsd:element name="Policy" type="Policy" minOccurs="0" maxOccurs="unbounded" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="Income">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="Amount" type="xsd:decimal" minOccurs="0" form="qualified"/>
<xsd:element name="EffectiveDate" type="xsd:dateTime" minOccurs="0" form="qualified"/>
<xsd:element name="Frequency" type="FrequencyCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Type" type="IncomeTypeCodes" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="Address">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="City" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Country" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Line1" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Line2" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Line3" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Line4" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="Class">
<xsd:complexContent>
<xsd:extension base="Structurable">
<xsd:sequence>
<xsd:element name="Code" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="EffectiveDate" type="xsd:dateTime" minOccurs="0" form="qualified"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="BenefitDecline">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="ChangeEffectiveDate" type="xsd:dateTime" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="DeclineReason" type="CancelReasonCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Declined" type="xsd:boolean" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="LineOfBusinessCategory" type="LineOfBusinessCategoryCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="ReapplicationReason" type="ReapplicationReasonCodes" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="ArrayOfCoveredLife">
<xsd:sequence>
<xsd:element name="CoveredLife" type="CoveredLife" minOccurs="0" maxOccurs="unbounded" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="ArrayOfContactInformation">
<xsd:sequence>
<xsd:element name="ContactInformation" type="ContactInformation" minOccurs="0" maxOccurs="unbounded" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="Division">
<xsd:complexContent>
<xsd:extension base="Structurable">
<xsd:sequence>
<xsd:element name="Code" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="SubDivisions" type="ArrayOfDivision" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="EffectiveDate" type="xsd:dateTime" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="Certificate">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="Class" type="Class" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="CurrentEmploymentRecord" type="EmploymentRecord" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="CurrentIncome" type="Income" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Dependents" type="ArrayOfCoveredLife" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Division" type="Division" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="FamilyCategory" type="FamilyCategoryCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="HealthCareSpendingAccountInformation" type="HealthCareSpendingAccountInformation" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="HireDate" type="xsd:dateTime" minOccurs="0" form="qualified"/>
<xsd:element name="InsuredCoveredLife" type="CoveredLife" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="JobTitle" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Number" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="PayrollNumber" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Plan" type="Plan" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="RegionalAdministration" type="RegionalAdministrativeInformation" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="Section" type="Section" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="CoveredLife">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="ApplicationDate" type="xsd:dateTime" minOccurs="0" form="qualified"/>
<xsd:element name="CancelReason" type="CancelReasonCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="CoverageDeclines" type="ArrayOfBenefitDecline" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="CoveredLifeHolder" type="Person" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="DependentCategory" type="DependentCategoryCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="DependentSubCategory" type="DependentSubCategoryCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="EffectiveDate" type="xsd:dateTime" minOccurs="0" form="qualified"/>
<xsd:element name="Number" type="xsd:string" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="QualificationDate" type="xsd:dateTime" minOccurs="0" form="qualified"/>
<xsd:element name="Status" type="CoveredLifeStatusCodes" minOccurs="0" form="qualified" nillable="true"/>
<xsd:element name="TerminationDate" type="xsd:dateTime" minOccurs="0" form="qualified"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
<xsd:complexType name="Enrollment">
<xsd:complexContent>
<xsd:extension base="BusinessObject">
<xsd:sequence>
<xsd:element name="Policies" type="ArrayOfPolicy" minOccurs="0" form="qualified" nillable="true"/>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:schema>
While I am mapping I can see Default address like attached pic, during data it is inserted dynamic node called " type,postal code and province."
How to map these dynamic node in my message mapping
Thank you
John