#### XML

#### Synopsis

    HELP:   Write a data field in XML format
    TYPE:   OBJECT
    SYNTAX: XML(ROOT='str',PATH='str',VALUE='str',COMMENT='str',SCHEME=STRUCTURED/UNSTRUCTURED,LINEFD=num,INDSIZE=num,INDCHAR/INDCHR=SPACE/TABULATOR,NAMESPACE/NS[()...],USENID,NOESCP)

#### Description

This object is used to transform data stored in table format into an XML document. If one column format is set to XML, then all column formats of all row specifications must be set to XML.

Data elements are addressed via root and path strings in a hierarchical path syntax. The syntax equals that of the corresponding 'read' object. So, please refer to its documentation first to understand the underlying concepts.

The only difference when writing XML is the '%' and '!' characters. The '%' can be used to put a data element inside a CDATA section.

       ROW(
          NAME='row'
          COLUMN(NAME='col1' root='table/row' path='simple/value')
          COLUMN(NAME='col2' root='table/row' path='complex/%value')
       )

In this example, the value under the path table/row/complex/value is put inside a CDATA section due to the % before the leaf's name:

    <?xml version='1.0'?>
    <table>
      <row>
         <simple>
           <value>Data11</value>
         </simple>
         <complex>
           <value><![CDATA[Data12]]></value>
         </complex>
      </row>
    <table>

The '!' character can be used to enforce print of a complete branch if a header change was detected. By default only for the changed value the print flag is activated. If it is required to print the whole branch if a column change was detected as part of this branch then this branch must be mark with '!' in the root or path definition of the header column. This is also required if a lower start level must be ensured if a header change was detected. Below you can find a sample for some SEPA XML format, where the complete branch'BBkDNF:FIToFICstmrDrctDbt' must be printed if a header change in such a column occur:

    format=xml defaults(witspc=collapse frasep=period type=string fradig=2)
     row(name=FIToFIPmtStsRpt
        col(name=PACS312-F000-xmlns       root='BBkDNF:BBkDNFBlkDirDeb' path='&xmlns:BBkDNF')
        col(name=PACS312-F000-xsi         root='BBkDNF:BBkDNFBlkDirDeb' path='&xmlns:xsi')
        col(name=PACS312-F000-sl          root='BBkDNF:BBkDNFBlkDirDeb' path='&xsi:schemaLocation')
        col(name=PACS312-F001-SndgInst    root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:SndgInst')
        col(name=PACS312-F002-RcvgInst    root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:RcvgInst')
        col(name=PACS312-F003-SrvcId      root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:SrvcId')
        col(name=PACS312-F004-TstCode     root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:TstCode')
        col(name=PACS312-F005-FType       root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:FType')
        col(name=PACS312-F006-FileRef     root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:FileRef')
        col(name=PACS312-F007-FileBusDt   root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:FileBusDt')
        col(name=PACS312-F008-RoutingInd  root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:RoutingInd')
        col(name=PACS312-F009-FileCycleN  root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:FileCycleNo')
        col(name=PACS312-F010-NumDDBlk    root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:NumDDBlk' type.integer(format.str(digits=7)))
        col(name=PACS312-F011-NumPCRBlk   root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:NumPCRBlk' type.integer(format.str(digits=7)))
        col(name=PACS312-F012-NumREJBlk   root='BBkDNF:BBkDNFBlkDirDeb' path='BBkDNF:NumREJBlk' type.integer(format.str(digits=7)))
        col(name=PACS312-B000-xmlns       root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='&xmlns')
        col(name=PACS312-B001-MsgId       root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='GrpHdr/MsgId')
        col(name=PACS312-B002-CreDtTm     root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='GrpHdr/CreDtTm')
        col(name=PACS312-B003-NbOfTxs     root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='GrpHdr/NbOfTxs' type.integer(format.str(digits=7)))
        col(name=PACS312-B004-SttlmAmt    root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='GrpHdr/TtlIntrBkSttlmAmt' type.float())
        col(name=PACS312-B005-SttlmCcy    root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='GrpHdr/TtlIntrBkSttlmAmt/?&Ccy')
        col(name=PACS312-B006-SttlmDt     root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='GrpHdr/IntrBkSttlmDt')
        col(name=PACS312-B007-SttlmMtd    root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='GrpHdr/SttlmInf/SttlmMtd')
        col(name=PACS312-B008-Prtry       root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='GrpHdr/SttlmInf/ClrSys/Prtry')
        col(name=PACS312-B009-Instg-BIC   root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='GrpHdr/?InstgAgt/FinInstnId/BIC')
        col(name=PACS312-B010-Instd-BIC   root='BBkDNF:BBkDNFBlkDirDeb/?!BBkDNF:FIToFICstmrDrctDbt' path='GrpHdr/?InstdAgt/FinInstnId/BIC')
        col(name=PACS312-T001-InstrId     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='PmtId/?InstrId')
        col(name=PACS312-T002-EndToEndId  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='PmtId/EndToEndId')
        col(name=PACS312-T003-PmtId-TxId  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='PmtId/TxId')
        col(name=PACS312-T004-SvcLvl-Cd   root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='PmtTpInf/SvcLvl/Cd')
        col(name=PACS312-T005-LclInst-Cd  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='PmtTpInf/LclInstrm/Cd')
        col(name=PACS312-T006-SeqTp       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='PmtTpInf/SeqTp')
        col(name=PACS312-T007-Purp-Cd     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='PmtTpInf/?CtgyPurp/?Cd')
        col(name=PACS312-T008-Prtry       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='PmtTpInf/?CtgyPurp/?Prtry')
        col(name=PACS312-T009-SttlmAmt    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='IntrBkSttlmAmt' type.float())
        col(name=PACS312-T010-SttlmCcy    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='IntrBkSttlmAmt/?&Ccy')
        col(name=PACS312-T011-ChrgBr      root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='ChrgBr')
        col(name=PACS312-T012-ReqdColltn  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='ReqdColltnDt')
        col(name=PACS312-T013-MndtId      root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/MndtId')
        col(name=PACS312-T014-DtOfSgntr   root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/DtOfSgntr')
        col(name=PACS312-T015-AmdmntInd   root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/?AmdmntInd')
        col(name=PACS312-T016-OrgnlMndtI  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/?AmdmntInfDtls/?OrgnlMndtId')
        col(name=PACS312-T017-OrgnlCd-Nm  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/?AmdmntInfDtls/?OrgnlCdtrSchmeId/?Nm')
        col(name=PACS312-T018-OrgnlCd-Id  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/?AmdmntInfDtls/?OrgnlCdtrSchmeId/?Id/PrvtId/Othr/Id')
        col(name=PACS312-T019-Prtry       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/?AmdmntInfDtls/?OrgnlCdtrSchmeId/?Id/PrvtId/Othr/SchmeNm/Prtry')
        col(name=PACS312-T020-ODbtr-IBAN  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/?AmdmntInfDtls/?OrgnlDbtrAcct/Id/?IBAN')
        col(name=PACS312-T021-ODbtr-Id    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/?AmdmntInfDtls/?OrgnlDbtrAcct/Id/?Othr/Id')
        col(name=PACS312-T022-ODbtr-BIC   root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/?AmdmntInfDtls/?OrgnlDbtrAgt/FinInstnId/BIC')
        col(name=PACS312-T023-ElctrncSgn  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/MndtRltdInf/?ElctrncSgntr')
        col(name=PACS312-T024-Cdtr-Id     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/CdtrSchmeId/Id/PrvtId/Othr/Id')
        col(name=PACS312-T025-Prtry       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DrctDbtTx/CdtrSchmeId/Id/PrvtId/Othr/SchmeNm/Prtry')
        col(name=PACS312-T026-Cdtr-Nm     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Cdtr/Nm')
        col(name=PACS312-T027-PstlA-Ctry  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Cdtr/?PstlAdr/?Ctry')
        col(name=PACS312-T028-AdrLine     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Cdtr/?PstlAdr/?AdrLine')
        col(name=PACS312-T029-AdrLine     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Cdtr/?PstlAdr/?AdrLine')
        col(name=PACS312-T030-Cdtr-IBAN   root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='CdtrAcct/Id/IBAN')
        col(name=PACS312-T031-Cdtr-BIC    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='CdtrAgt/FinInstnId/BIC')
        col(name=PACS312-T032-UCdtr-Nm    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Nm')
        col(name=PACS312-T033-BICOrBEI    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?OrgId/?BICOrBEI')
        col(name=PACS312-T034-UCdtr-Id    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?OrgId/?Othr/Id')
        col(name=PACS312-T035-UCdtr-Cd    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?OrgId/?Othr/?SchmeNm/?Cd')
        col(name=PACS312-T036-Prtry       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?OrgId/?Othr/?SchmeNm/?Prtry')
        col(name=PACS312-T037-UCdtr-Issr  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?OrgId/?Othr/?Issr')
        col(name=PACS312-T038-BirthDt     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?PrvtId/?DtAndPlcOfBirth/BirthDt')
        col(name=PACS312-T039-PrvcOfBirt  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?PrvtId/?DtAndPlcOfBirth/?PrvcOfBirth')
        col(name=PACS312-T040-CityOfBirt  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?PrvtId/?DtAndPlcOfBirth/CityOfBirth')
        col(name=PACS312-T041-CtryOfBirt  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?PrvtId/?DtAndPlcOfBirth/CtryOfBirth')
        col(name=PACS312-T042-UCdtr-Id    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?PrvtId/?Othr/Id')
        col(name=PACS312-T043-UCdtr-Cd    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?PrvtId/?Othr/?SchmeNm/?Cd')
        col(name=PACS312-T044-Prtry       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?PrvtId/?Othr/?SchmeNm/?Prtry')
        col(name=PACS312-T045-UCdtr-Issr  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtCdtr/?Id/?PrvtId/?Othr/?Issr')
        col(name=PACS312-T046-Instg-BIC   root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?InstgAgt/FinInstnId/BIC')
        col(name=PACS312-T047-Dbtr-Nm     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/Nm')
        col(name=PACS312-T048-PstlA-Ctry  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?PstlAdr/?Ctry')
        col(name=PACS312-T049-AdrLine     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?PstlAdr/?AdrLine')
        col(name=PACS312-T050-AdrLine     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?PstlAdr/?AdrLine')
        col(name=PACS312-T051-BICOrBEI    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?OrgId/?BICOrBEI')
        col(name=PACS312-T052-Dbtr-Id     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?OrgId/?Othr/Id')
        col(name=PACS312-T053-Dbtr-Cd     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?OrgId/?Othr/?SchmeNm/?Cd')
        col(name=PACS312-T054-Prtry       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?OrgId/?Othr/?SchmeNm/?Prtry')
        col(name=PACS312-T055-Dbtr-Issr   root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?OrgId/?Othr/?Issr')
        col(name=PACS312-T056-BirthDt     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?PrvtId/?DtAndPlcOfBirth/BirthDt')
        col(name=PACS312-T057-PrvcOfBirt  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?PrvtId/?DtAndPlcOfBirth/?PrvcOfBirth')
        col(name=PACS312-T058-CityOfBirt  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?PrvtId/?DtAndPlcOfBirth/CityOfBirth')
        col(name=PACS312-T059-CtryOfBirt  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?PrvtId/?DtAndPlcOfBirth/CtryOfBirth')
        col(name=PACS312-T060-Dbtr-Id     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?PrvtId/?Othr/Id')
        col(name=PACS312-T061-Dbtr-Cd     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?PrvtId/?Othr/?SchmeNm/?Cd')
        col(name=PACS312-T062-Prtry       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?PrvtId/?Othr/?SchmeNm/?Prtry')
        col(name=PACS312-T063-Dbtr-Issr   root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='Dbtr/?Id/?PrvtId/?Othr/?Issr')
        col(name=PACS312-T064-Dbtr-IBAN   root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DbtrAcct/Id/IBAN')
        col(name=PACS312-T065-Dbtr-BIC    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='DbtrAgt/FinInstnId/BIC')
        col(name=PACS312-T066-UDbtr-Nm    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Nm')
        col(name=PACS312-T067-BICOrBEI    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?OrgId/?BICOrBEI')
        col(name=PACS312-T068-UDbtr-Id    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?OrgId/?Othr/Id')
        col(name=PACS312-T069-UDbtr-Cd    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?OrgId/?Othr/?SchmeNm/?Cd')
        col(name=PACS312-T070-Prtry       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?OrgId/?Othr/?SchmeNm/?Prtry')
        col(name=PACS312-T071-UDbtr-Issr  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?OrgId/?Othr/?Issr')
        col(name=PACS312-T072-BirthDt     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?PrvtId/?DtAndPlcOfBirth/BirthDt')
        col(name=PACS312-T073-PrvcOfBirt  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?PrvtId/?DtAndPlcOfBirth/?PrvcOfBirth')
        col(name=PACS312-T074-CityOfBirt  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?PrvtId/?DtAndPlcOfBirth/CityOfBirth')
        col(name=PACS312-T075-CtryOfBirt  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?PrvtId/?DtAndPlcOfBirth/CtryOfBirth')
        col(name=PACS312-T076-UDbtr-Id    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?PrvtId/?Othr/Id')
        col(name=PACS312-T077-UDbtr-Cd    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?PrvtId/?Othr/?SchmeNm/?Cd')
        col(name=PACS312-T078-Prtry       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?PrvtId/?Othr/?SchmeNm/?Prtry')
        col(name=PACS312-T079-UDbtr-Issr  root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?UltmtDbtr/?Id/?PrvtId/?Othr/?Issr')
        col(name=PACS312-T080-Purp-Cd     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?Purp/?Cd')
        col(name=PACS312-T081-Ustrd       root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?RmtInf/?Ustrd')
        col(name=PACS312-T082-Strd-Cd     root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?RmtInf/?Strd/?CdtrRefInf/Tp/CdOrPrtry/?Cd')
        col(name=PACS312-T083-Strd-Issr   root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?RmtInf/?Strd/?CdtrRefInf/Tp/?Issr')
        col(name=PACS312-T084-Strd-Ref    root='BBkDNF:BBkDNFBlkDirDeb/?BBkDNF:FIToFICstmrDrctDbt/DrctDbtTxInf' path='?RmtInf/?Strd/?CdtrRefInf/Ref')
     )

Hint: When reading, the '%' and '!' is optional and ignored, so the same root/path definition can be used for both, reading and writing XML. To support different EBCDIC code pages the pipe symbol '|' will be a synonym for '!'. The '!' at read is used for the last path component (leaf) to disallow empty fields and at write it can be used somewhere on the path but not for the leaf.

If no root path is specified, then '<table/row>' is the default when using the structured XML scheme and '<table>' is used for the unstructured scheme. This means that, the root path should contain at least two elements in the structured version: One to enclose the whole document/table (i.e. the root tag) and the second to enclose each row. By default, the table name of the row specification is used to enclose the table (as root tag) in the structured and unstructured variant. In the structured scheme there is no default name to enclose each row and the literal 'row' is then used to build a valid structured XML document. Since version 5.1.25 of FLAM XML files with only one level are supported in the structured version, if the root and path given. This is required if only a header as one line/row/transaction in the data (SWIFT-MX).

When writing, the order of the columns defines the order of elements in the XML document. Therefore, branches with multiple sub-branches and tags must be grouped together. Otherwise, they are written out as multiple distinct branches.

By default, each element is printed on a separate line with, indented by 2 whitespace characters (pretty printing). The indentation amount and character can be configured, if needed. If the tabulator is used, then the default indentation amount is 1. The number of line feeds printed between elements can be controlled as well. By setting the LINEFD and INDSIZE parameters to 0, a minimized output without any added whitespace or line breaks is generated.

By default, characters that are part of the XML syntax, are written as escape sequences as required by the XML specification (e.g. & => &amp;). Scanning for these characters has a performance impact. If the processed data is known to not contain any of these characters (e.g.: <>"'&) and performance is important, the NOESCP flag can be set. This disables the scanning of all data for characters that need to be escaped, speeding up the writing of the XML document.

If data is written as a CDATA section (element name prefixed with %) and the data contains the CDATA end sequence ']]>', that sequence leads to a split of the CDATA section into two CDATA sections to prevent a premature end of the CDATA section (and thus a broken XML document): ']]]]><![CDATA[>' This behavior is also disabled if the NOESCP flag is set.

For the structured version, which accounts for the beginning and end of a row, optional values and branches are supported by using the question mark (?) in the path. The logic to determine if a value or a branch is optional and must not be printed, depends on the provided default value. If the value in the table equals the provided default value and the item is marked as optional, then this item will not be printed. For a branch, all items within this optional branch must match the default value to make this branch optional. If an optional branch's children contain at least one non-default value, then all non-optional children of this branch are printed. The default value for binary and strings is the empty string. For integer and float types, '0' is the default value.

For optional fields, a null indication is implemented when reading. When writing a null-indication-dependent procedure can be activated. If an optional value in the XML data is equal to the defined default value, the value is not written, except if the null-indication is used when writing. This, however, only works if no other format is in between where the null indication information is lost. With the VAR formats PFLGLENPTR and PPTRLENFLG, you can define the null-indication bit through the flag word or keep it between read and write operation.

To print header values, the value must differ between the last and the current row. In this case, the table end and table begin processing is done based on the differences in the header values.

When reading XML, actual data can exist anywhere within the XML tree:

    <?xml version='1.0'?>
    <table>
      <row>
         <simple>
           Data10
           <value>Data11</value>
           Data12
         </simple>
      </row>
    <table>

This XML document can be read with the following row specification:

       ROW(
          NAME='row'
          COLUMN(NAME='col1' root='table/row' path='simple')
          COLUMN(NAME='col2' root='table/row' path='simple/value')
          COLUMN(NAME='col3' root='table/row' path='simple')
       )

However, writing data into non-leaf XML tags is currently not supported. Writing the same data with the row specification above, results in the XML document below:

    <?xml version='1.0'?>
    <table>
      <row>
         <simple>Data10</simple>
         <simple>
           <value>Data11</value>
         </simple>
         <simple>Data12</simple>
      </row>
    <table>

This version can be read with the same row specification. If writing data into non-leaf parts of an XML branch is a necessity, please contact us for a solution.

#### Name space support

XML name spaces must normally be handled by the application. Since version 5.1.24 with the selection 'PREFIX' the name space abbreviations can be exclude from tag comparisons. At write this requires, that only tree wide name space definitions are possible and must be defined as attribute for this tree by the application.

In a later version we plan to support name space objects to define the name space URI for each column. At read this URI will be validated unless the prefix selection is defined. At write the name space will be defined if possible per tree and only for elements where a local name space is required the given name space abbreviation is used.

#### Other things and recommendations

For SEPA, SWIFT-MX or other complex formats it would be useful to use a row definition generator using the specification given XSD or something like this. In this case it would be useful to generate each format as an own row specification into a simple text file. Later you can build several table specification be combining these different generated row specifications.

    ...
    table(format=xml defaults(...)
     row='ssh://user@my.format.server.org/pain008.txt/&UTF-8'
     row='ssh://user@my.format.server.org/pacs008.txt/&UTF-8'
     row='ssh://user@my.format.server.org/camt054.txt/&UTF-8'
    )
    ...

In this example a central format server is used as repository for all row specification available in the company. The access is done per SSH and the format descriptions are encoded in UTF-8.

#### Arguments

- `STRING: ROOT='str' - Root to XML element [taken from table/row/column]`
- `STRING: PATH='str' - Path to XML element [taken from column]`
- `STRING: VALUE='str' - Optional default value, to determine if a element optional ['0' for float and integer else '']`
- `STRING: COMMENT='str' - Add a comment to the XML data stream [default]`
- `NUMBER: SCHEME=STRUCTURED/UNSTRUCTURED - Scheme for XML writing [STRUCTURED]`
  - `STRUCTURED - Structured XML with enclosing tag for each row`
  - `UNSTRUCTURED - Unstructured XML with enclosing tag only for the table`
- `NUMBER: LINEFD=num - Amount of line feeds in front of each line [1]`
- `NUMBER: INDSIZE=num - Define indentation size for XML writing [2 if space, 1 if tab]`
- `NUMBER: INDCHAR/INDCHR=SPACE/TABULATOR - Indentation character used to indent XML tags [SPACE]`
  - `SPACE - Use the space character as indentation character`
  - `TABULATOR - Use the tabulator character as indentation character`
- `SWITCH: USENID - Use null indication for write [FALSE]`
- `SWITCH: NOESCP - Don't escape XML syntax elements (prevent double read and copy of data to add &...; sequences) [FALSE]`