Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

how to convert xml to csv without specifying schema to tFileInputXML

Hi,
I want to convert XML file into CSV file. I have XML which doesn't have fixed format every time. So how I convert that XML file into CSV file without specify schema in the tFileInputXML component.
I have simply design my job like
tFileInputXML------> tFileOutputDelimited
(schema not fixed)
Please help me.
Labels (4)
6 Replies
Anonymous
Not applicable
Author

Hi,
First of all, you should make sure your XML file is well-formed and then you can use talend component tFileInputXML to retrieve your attribution into relational table.
Here is the related forums: https://community.talend.com/t5/Design-and-Development/Unable-to-use-tFileInputXML/td-p/73056
Best regards
Sabrina
Anonymous
Not applicable
Author

Hi Sabrina,
My XML file is well formatted but the schema in the file are not fixed every time. So what I have to specify in the schema of tFileInputXML? Is there any way to define dynamic schema?
Anonymous
Not applicable
Author

Hi,
We have a "dynamic schema" feature, however, that is only available in Talend Enterprise Subscription Version, it allows you to design schema with an unknown column structure (unknown name and number of columns), however, tFileInputXML component does not support dynamic schema, so it is impossible to achieve your request.
Best regards
Sabrina
Anonymous
Not applicable
Author

Hi,
Here is a related forum https://community.talend.com/t5/Design-and-Development/tFileInputExcel-dynamic-schema/td-p/104738, hope it will point you a light on dynamic schema in XML file.
Perhaps you can create a custom component for your case. componentCreation
Best regards
Sabrina
Anonymous
Not applicable
Author

Hi,
I'm using enterprise version of Talend so how I will convert xml to csv without specified schema?
Anonymous
Not applicable
Author

Hi,
I was facing similar situation :-), but my XML was full of different namespaces, etc. and I wasn't able to get it working like this. The more complex XML the more complex job...
So I found a temporary workaround, you can open any XML file as table in Excel (it worked excellent in my case). So this way you have 2 options how to automate it via talend:
On Windows:
Create java wrapper for comp objects and develop "Excel open XML as CSV"
On Linux:
Try to do the same with Apache-POI libraries. This will work on Windows as well of course.
Let me know about your success. I found Talend XML processing very poor especially in Web Service domain...
Ladislav