Skip to Content
avatar image
Former Member

iflow in HCI having error at csv to xml converter step

hey guys,

working in HCI on a iflow, in which input is a csv file. so in the iflow, i put a SFTP step, to get the file, then a converter step for CSV to XML converter.

in the csv file, the data is something like:

1,2,3

4,5,6

7,8,9

meaning multiple records with 3 fields in it.

i created a data type, msg type in PI IR for it, then exported its XSD from message type, then even imported in PI as external definition and i can see the structure of the file in hierarchy as:

Msgtpye-

record-

field1,field2,field3

then imported that XSD in the integration project in HCI where the above iflow is created.

in converter step in properties, in XML schema - browse this XSD.

then path to target element in XSD - /ns0:messagetype/record

record marker in csv - \n

field separator in csv - comma

also in runtime configuration of iflow, specified ns0 = the namespace in which the message type was created in IR in PI system.

then outputted the data from another SFTP to get the XML file.

on deploying and running the above iflow, i get error Element name [] not found in provided XML schema file - which is occuring at converter step.

pls tell how to fix this error and how to get XML file generated from csv file from an iflow in HCI.

all helpful replies will be appreciated. thx.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Jan 14, 2016 at 11:12 AM

    Hello Stewart,

    If your target XML requirement is something below then please follow below steps

    Required output Structure:

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

         <Msgtpye>

             <Record>

                 <field1>1</field1>

                 <field2>2</field2>

                 <field3>3</field3>   

             </Record>

             <Record>

                 <field1>11</field1>

                 <field2>22</field2>

                 <field3>33</field3>   

             </Record>

             <Record>

                 <field1>111</field1>

                 <field2>222</field2>

                 <field3>333</field3>   

             </Record>

         </Msgtpye>

    Incoming CSV Structure:

    1,2,3

    11,22,33

    111,222,333

    Steps to perform:

    1) Create XSD for above XML manually or from online tool like freeformatter.com.

    2) Import the Schema into src.main.resources.xsd package of your integration project.

    3) Path to Target Element in XSD: Msgtpye/Record

    4) Record Marker in CSV : leave it blank

    5) Field separator in CSV :    Comma(,)

    Let me know if you face any issues again.

    Regards,

    Sriprasad Shivaram Bhat

    Add comment
    10|10000 characters needed characters exceeded