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

[tFileoutputXML] Delete the "row tag"

Hi all,
When I generate an XML File, there automatically is the "row tag". Idon't want it to be included. I haven't seen any option that permits that.
How to manage that?
For example, in this XML File, the "row tag" is useless. nevertheless, it"s automatically included.
<?xml version="1.0" encoding="ISO-8859-15"?>
<N_PERIOD>
<row>
<YEAR_DF>1985</YEAR_DF>
</row>
<row>
<YEAR_DF>1986</YEAR_DF>
</row>
<row>
<YEAR_DF>1987</YEAR_DF>
</row>
<row>
<YEAR_DF>1988</YEAR_DF>
</row>
</N_PERIOD>

Thanks!
mathieu
Labels (3)
6 Replies
Anonymous
Not applicable
Author

hi,
when you write into a output xml file you may specify the name of Document element (root) in the 'row tag' ...
ok ! a little screen shoot for an SVG document for example
++
laurent
Anonymous
Not applicable
Author

hello,
Thanks for your answer
I put "N_PERIOD" as "row tag", which is also the root tag of my XML but it didn't work.
Could you tell me which "row tag" I have to put, in my case
Thanks!
Mat'
Anonymous
Not applicable
Author

sorry ,
i've made a mistake :it's specified the name of the row (element) an wrap each row into this element ...
still have root document name = "row" at least
i've answer a little bit too fast ...
did you try with new component 3.1 like twritexmlfield !?
edit : have a look at https://community.talend.com/t5/Design-and-Development/tWriteXMLField-How-to-use-it/td-p/99251 ...
I have learn something more today 0683p000009MACn.png
Anonymous
Not applicable
Author

Hello mathieu_r
When you output xml file, there must exist a loop element. Here, row tag is the loop element. So, we can't ignore it on output component.
Well, you can write some Java code to delete row tag after you output the xml file.
Best regards
shong
Anonymous
Not applicable
Author

Ok thanks for your answer 0683p000009MA9p.png
Anonymous
Not applicable
Author

I would advise to use xslt to structure the output xml as you need to.
But it's true, the first time, xsl-t doesn't seems easy. But manipulating hierarchical data is quite different to tabular, so it needs a different approach.