<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Add a header from a context or another file in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361904#M126151</link>
    <description>&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i had a problem adding a header in a dynamic file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I previously processed a file and in the output of the tjavarow I have the out field with the OBJECT type. I tried to insert it in the tjavarow but it prints the header for each row. However, the created file has no header. How do I add the header that I saved as context or as a column of another file?&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0695b00000qPn5EAAS.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/138861iE2E241D04263344B/image-size/large?v=v2&amp;amp;px=999" role="button" title="0695b00000qPn5EAAS.png" alt="0695b00000qPn5EAAS.png" /&gt;&lt;/span&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 15 Nov 2024 21:20:11 GMT</pubDate>
    <dc:creator>lcupito</dc:creator>
    <dc:date>2024-11-15T21:20:11Z</dc:date>
    <item>
      <title>Add a header from a context or another file</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361904#M126151</link>
      <description>&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i had a problem adding a header in a dynamic file.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I previously processed a file and in the output of the tjavarow I have the out field with the OBJECT type. I tried to insert it in the tjavarow but it prints the header for each row. However, the created file has no header. How do I add the header that I saved as context or as a column of another file?&lt;/P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0695b00000qPn5EAAS.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/138861iE2E241D04263344B/image-size/large?v=v2&amp;amp;px=999" role="button" title="0695b00000qPn5EAAS.png" alt="0695b00000qPn5EAAS.png" /&gt;&lt;/span&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 15 Nov 2024 21:20:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361904#M126151</guid>
      <dc:creator>lcupito</dc:creator>
      <dc:date>2024-11-15T21:20:11Z</dc:date>
    </item>
    <item>
      <title>Re: Add a header from a context or another file</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361905#M126152</link>
      <description>&lt;P&gt;Hi  &lt;/P&gt;&lt;P&gt;Hope this KB article is helpful for you, it shows how to update the column properties including the column name when using Dynamic schema. &lt;/P&gt;&lt;P&gt;https://community.talend.com/s/article/Updating-column-properties-when-using-Dynamic-schema&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Shong&lt;/P&gt;</description>
      <pubDate>Sat, 14 Oct 2023 17:37:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361905#M126152</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-10-14T17:37:28Z</dc:date>
    </item>
    <item>
      <title>Re: Add a header from a context or another file</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361906#M126153</link>
      <description>&lt;P&gt;It's not for me, but thank you anyway.&lt;/P&gt;</description>
      <pubDate>Sat, 14 Oct 2023 18:10:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361906#M126153</guid>
      <dc:creator>lcupito</dc:creator>
      <dc:date>2023-10-14T18:10:49Z</dc:date>
    </item>
    <item>
      <title>Re: Add a header from a context or another file</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361907#M126154</link>
      <description>&lt;P&gt;can you show us the java code on tJavaRow? If I understand your requirement well, you need to access the column properties, get the column name and replace it with new name from context variable.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 16 Oct 2023 05:18:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361907#M126154</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2023-10-16T05:18:16Z</dc:date>
    </item>
    <item>
      <title>Re: Add a header from a context or another file</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361908#M126155</link>
      <description>&lt;P&gt;This is my tJavaRow code:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;String[] headers = context.W_INTESTAZIONE.split("\\|");&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;String result = "";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;for (String header: headers) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;Object columnValue = input_row.data.getColumnValue(header);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;if (columnValue != null) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;result += columnValue.toString() + "|";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;} else {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;result += "null|";&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;if (result.endsWith("|")) {&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;result = result.substring(0, result.length() - 1);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;output_row.out = result;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In context.W_INTESTAZIONE.split("\\|") i have the headers passed from father job (column1|column2|column3 etc etc) and in output (Object datatype) i have only the value without headers. i need as a first row the header and the value after the first row.&lt;/P&gt;</description>
      <pubDate>Mon, 16 Oct 2023 17:05:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361908#M126155</guid>
      <dc:creator>lcupito</dc:creator>
      <dc:date>2023-10-16T17:05:47Z</dc:date>
    </item>
    <item>
      <title>Re: Add a header from a context or another file</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361909#M126156</link>
      <description>&lt;P&gt;Thank you for the article link, you made my day &lt;span class="lia-unicode-emoji" title=":smiling_face_with_smiling_eyes:"&gt;😊&lt;/span&gt; &lt;/P&gt;</description>
      <pubDate>Tue, 07 Nov 2023 07:01:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Add-a-header-from-a-context-or-another-file/m-p/2361909#M126156</guid>
      <dc:creator>CMolloy1698391524</dc:creator>
      <dc:date>2023-11-07T07:01:20Z</dc:date>
    </item>
  </channel>
</rss>

