<?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 Re: output_row.variable in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/output-row-variable/m-p/2251669#M35554</link>
    <description>&lt;P&gt;First of all you need to understand that the tJavaRow uses "input_row.{column_name}" to receive column values from your row and the&amp;nbsp;&lt;SPAN&gt;"output_row.{column_name}" to set column values for the output row. So in your job, wherever "output_row" is used, it is basically setting the column value for the row leaving the component.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;In the code below, the first&amp;nbsp;SetExecLoad component is testing the value held by the message column. If it is "failure" then it sets an execload boolean to true, otherwise it sets it to false. This is not necessary as it is initialised to false above. It prints out the value of the execload to the output window and passes the execload value to the output_row.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;In the second SetExecLoad component it essentially does the same but the setting of execload to true is based on the tRedshiftInput component returning 0 rows.&lt;/SPAN&gt;&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;This bit of code.....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;globalMap.put(&lt;/SPAN&gt;&lt;SPAN class="s1"&gt;"ExecLoad"&lt;/SPAN&gt;&lt;SPAN&gt;,input_row.execload);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;....sets the globalMap hashmap to have a value supplied by input_row.execload, linked to the key "ExecLoad". It can be retrieved with the following code.....&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;((Boolean)globalMap.get(&lt;SPAN class="s1"&gt;"ExecLoad"&lt;/SPAN&gt;))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;....assuming that "input_row.execload" is a boolean.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 31 Aug 2018 09:25:17 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-08-31T09:25:17Z</dc:date>
    <item>
      <title>output_row.variable</title>
      <link>https://community.qlik.com/t5/Talend-Studio/output-row-variable/m-p/2251668#M35553</link>
      <description>&lt;P&gt;Hi Talend experts&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I have got few questions around output_row.variable not sure what this code is doing. can you please help me understand? (please refer&amp;nbsp;to below screenshot for job ParentCheckExecLoad job where speicifically code is written for SetExecLoad component).&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screen Shot 2018-08-31 at 8.51.57 am.png" style="width: 878px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009Lzk1.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/128312i4D7C2EB115E131B7/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009Lzk1.png" alt="0683p000009Lzk1.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;for first SetExecLoad code is written like this:&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;&lt;STRONG&gt;boolean&lt;/STRONG&gt;&lt;/SPAN&gt; execload = &lt;SPAN class="s1"&gt;&lt;STRONG&gt;false&lt;/STRONG&gt;&lt;/SPAN&gt;;&lt;/P&gt; 
&lt;P class="p2"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;&lt;STRONG&gt;if&lt;/STRONG&gt;&lt;/SPAN&gt; (input_row.message.equals(&lt;SPAN class="s2"&gt;"failure"&lt;/SPAN&gt;) )&lt;/P&gt; 
&lt;P class="p1"&gt;execload = &lt;SPAN class="s1"&gt;&lt;STRONG&gt;true&lt;/STRONG&gt;&lt;/SPAN&gt;;&lt;/P&gt; 
&lt;P class="p3"&gt;&lt;STRONG&gt;else&lt;/STRONG&gt;&lt;/P&gt; 
&lt;P class="p1"&gt;execload = &lt;SPAN class="s1"&gt;&lt;STRONG&gt;false&lt;/STRONG&gt;&lt;/SPAN&gt;;&lt;/P&gt; 
&lt;P class="p2"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;output_row.execload = execload;&lt;/P&gt; 
&lt;P class="p2"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;System.out.println(&lt;SPAN class="s2"&gt;"execload: &lt;SPAN class="Apple-converted-space"&gt;&amp;nbsp; &lt;/SPAN&gt;"&lt;/SPAN&gt;+execload);&lt;/P&gt; 
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;For the second SetExecLoad it's written like this:&lt;/P&gt; 
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;&lt;STRONG&gt;boolean&lt;/STRONG&gt;&lt;/SPAN&gt; execload = &lt;SPAN class="s1"&gt;&lt;STRONG&gt;false&lt;/STRONG&gt;&lt;/SPAN&gt;;&lt;/P&gt; 
&lt;P class="p2"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;&lt;SPAN class="s1"&gt;&lt;STRONG&gt;if&lt;/STRONG&gt;&lt;/SPAN&gt; (((Integer)globalMap.get(&lt;SPAN class="s2"&gt;"tRedshiftInput_1_NB_LINE"&lt;/SPAN&gt;)) == 0)&lt;/P&gt; 
&lt;P class="p1"&gt;execload = &lt;SPAN class="s1"&gt;&lt;STRONG&gt;true&lt;/STRONG&gt;&lt;/SPAN&gt;;&lt;/P&gt; 
&lt;P class="p2"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;output_row.execload = execload;&lt;/P&gt; 
&lt;P class="p2"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;System.out.println(&lt;SPAN class="s2"&gt;"output_row.execload:&lt;SPAN class="Apple-converted-space"&gt;&amp;nbsp; &lt;/SPAN&gt;"&lt;/SPAN&gt;+output_row.execload);&lt;/P&gt; 
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;Then this parentcheckexecload is being referred in another job like this and execload is also set as shown in below photo.&lt;/P&gt; 
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Screen Shot 2018-08-31 at 8.57.15 am.png" style="width: 566px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009Lzi6.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/138071i0E3AB7DF7B47E728/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009Lzi6.png" alt="0683p000009Lzi6.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;For this SetExecLoad below code is written:&lt;/P&gt; 
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;globalMap.put(&lt;SPAN class="s1"&gt;"ExecLoad"&lt;/SPAN&gt;,input_row.execload);&lt;/P&gt; 
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;I have no idea what does this actually do. Can someone please explain?&lt;/P&gt; 
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P class="p1"&gt;Thanks&lt;/P&gt; 
&lt;P class="p1"&gt;Harshal&lt;/P&gt; 
&lt;P class="p1"&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 07:44:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/output-row-variable/m-p/2251668#M35553</guid>
      <dc:creator>Parikhharshal</dc:creator>
      <dc:date>2024-11-16T07:44:34Z</dc:date>
    </item>
    <item>
      <title>Re: output_row.variable</title>
      <link>https://community.qlik.com/t5/Talend-Studio/output-row-variable/m-p/2251669#M35554</link>
      <description>&lt;P&gt;First of all you need to understand that the tJavaRow uses "input_row.{column_name}" to receive column values from your row and the&amp;nbsp;&lt;SPAN&gt;"output_row.{column_name}" to set column values for the output row. So in your job, wherever "output_row" is used, it is basically setting the column value for the row leaving the component.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;In the code below, the first&amp;nbsp;SetExecLoad component is testing the value held by the message column. If it is "failure" then it sets an execload boolean to true, otherwise it sets it to false. This is not necessary as it is initialised to false above. It prints out the value of the execload to the output window and passes the execload value to the output_row.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;In the second SetExecLoad component it essentially does the same but the setting of execload to true is based on the tRedshiftInput component returning 0 rows.&lt;/SPAN&gt;&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;This bit of code.....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;globalMap.put(&lt;/SPAN&gt;&lt;SPAN class="s1"&gt;"ExecLoad"&lt;/SPAN&gt;&lt;SPAN&gt;,input_row.execload);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;....sets the globalMap hashmap to have a value supplied by input_row.execload, linked to the key "ExecLoad". It can be retrieved with the following code.....&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;((Boolean)globalMap.get(&lt;SPAN class="s1"&gt;"ExecLoad"&lt;/SPAN&gt;))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;....assuming that "input_row.execload" is a boolean.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 31 Aug 2018 09:25:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/output-row-variable/m-p/2251669#M35554</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-08-31T09:25:17Z</dc:date>
    </item>
    <item>
      <title>Re: output_row.variable</title>
      <link>https://community.qlik.com/t5/Talend-Studio/output-row-variable/m-p/2251670#M35555</link>
      <description>Hi rhall_2_0 
&lt;BR /&gt; 
&lt;BR /&gt;Thanks a lot for your reply. 
&lt;BR /&gt;Really appreciated. 
&lt;BR /&gt; 
&lt;BR /&gt;However, being new to Talend and Java world I still didn’t understand one thing which is this: 
&lt;BR /&gt; 
&lt;BR /&gt;wherever "output_row" is used, it is basically setting the column value for the row leaving the component. Can you please elaborate more? 
&lt;BR /&gt; 
&lt;BR /&gt;Thanks 
&lt;BR /&gt;Harshal.</description>
      <pubDate>Fri, 31 Aug 2018 22:16:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/output-row-variable/m-p/2251670#M35555</guid>
      <dc:creator>Parikhharshal</dc:creator>
      <dc:date>2018-08-31T22:16:45Z</dc:date>
    </item>
    <item>
      <title>Re: output_row.variable</title>
      <link>https://community.qlik.com/t5/Talend-Studio/output-row-variable/m-p/2251671#M35556</link>
      <description>&lt;P&gt;All of your data will pass&amp;nbsp;in rows through a Talend flow. Data enters a component in a row by row manner and leaves in the same way. In a tJavaRow you can receive the incoming row data to manipulate it using the input_row prefix, and when you have finished manipulating it you can send it to the next component using the output_row prefix.&lt;BR /&gt;&lt;BR /&gt;It is highly advisable that you learn a bit of Java while learning Talend. It makes understanding how to use the tool a lot easier. It also helps tremendously with debugging.&lt;/P&gt;</description>
      <pubDate>Sun, 02 Sep 2018 11:23:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/output-row-variable/m-p/2251671#M35556</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-09-02T11:23:55Z</dc:date>
    </item>
  </channel>
</rss>

