<?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: globalMap.get() is not working in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248499#M33334</link>
    <description>Can you show your component code instead of the Code tab?</description>
    <pubDate>Fri, 02 Jun 2017 19:04:59 GMT</pubDate>
    <dc:creator>cterenzi</dc:creator>
    <dc:date>2017-06-02T19:04:59Z</dc:date>
    <item>
      <title>globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248498#M33333</link>
      <description>&lt;P&gt;I am using a global map variable in a tJavaRow component. but its giving an error message.&lt;/P&gt; 
&lt;P&gt;"cannot make a static reference to the non-static field".&lt;/P&gt; 
&lt;P&gt;I am using BigData Spark job.&lt;/P&gt; 
&lt;P&gt;How Do i overcome this issue.&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="globalmapError.jpg" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009LuqS.jpg"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/131102i5B0E6013AA70F535/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009LuqS.jpg" alt="0683p000009LuqS.jpg" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 09:41:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248498#M33333</guid>
      <dc:creator>TomG1</dc:creator>
      <dc:date>2024-11-16T09:41:20Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248499#M33334</link>
      <description>Can you show your component code instead of the Code tab?</description>
      <pubDate>Fri, 02 Jun 2017 19:04:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248499#M33334</guid>
      <dc:creator>cterenzi</dc:creator>
      <dc:date>2017-06-02T19:04:59Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248500#M33335</link>
      <description>&lt;P&gt;I have created a simple mapping to show this error.&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="errorglobalmap.png" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009LuQl.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/144064i83B7F309E5CFC0B9/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009LuQl.png" alt="0683p000009LuQl.png" /&gt;&lt;/span&gt;&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;the error is coming from the tJavaRow component which i have shown in the first post.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;here is the code of the tjavarow component .&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;PRE&gt; String[] values = (String[])globalMap.get("values");
 
 row1.a = row2.a;
 row1.b = row2.b;&lt;/PRE&gt; 
&lt;P&gt;here is the code in tjava component&lt;/P&gt; 
&lt;PRE&gt;String[] values = { "This", "is", "test" };

globalMap.put("values", values);&lt;/PRE&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;try reproducing the error in you system.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;request to help me on this..&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 04 Jun 2017 12:35:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248500#M33335</guid>
      <dc:creator>TomG1</dc:creator>
      <dc:date>2017-06-04T12:35:57Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248501#M33336</link>
      <description>&lt;P&gt;&lt;A href="https://community.qlik.com/s/profile/null"&gt;@tomaszc&lt;/A&gt;, I tried the way you explained. For me it is working fine, i was able to get the values from globalMap in the tJavaRow.&lt;/P&gt; 
&lt;P&gt;I've exported my job (&lt;A href="https://www.dropbox.com/s/rv8kwlfpl8whuno/Test.zip?dl=0" target="_blank" rel="nofollow noopener noreferrer"&gt;Test.zip&lt;/A&gt;), you can download it&amp;nbsp;and have a look.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Hope this helps.&lt;/P&gt;</description>
      <pubDate>Sun, 04 Jun 2017 17:43:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248501#M33336</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-06-04T17:43:37Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248502#M33337</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am not able to open your job in talend.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;what kind of job is that.. is it standard or bigdata job?.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am specifically talking about Bigdata Spark job.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In Talend standard job , I am able to get the output . but the same code in talend big data is giving error.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am using 'Talend big data plaform 6.2'&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Sun, 04 Jun 2017 19:37:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248502#M33337</guid>
      <dc:creator>TomG1</dc:creator>
      <dc:date>2017-06-04T19:37:57Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248503#M33338</link>
      <description>&lt;P&gt;&lt;FONT face="tahoma,arial,helvetica,sans-serif" size="3"&gt;Sorry it was a standard job, not a&amp;nbsp;&lt;SPAN&gt;Bigdata Spark job. I will give it a try with&amp;nbsp;Bigdata Spark job.&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 05 Jun 2017 02:01:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248503#M33338</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-06-05T02:01:06Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248504#M33339</link>
      <description>&lt;P&gt;I am trying with an alternative&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I have created a context variable of type Object.&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="srccols.jpg" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009Lurp.jpg"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/145230iA5CD3817C2138433/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009Lurp.jpg" alt="0683p000009Lurp.jpg" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;To this variable I am saving my string array &amp;nbsp;in tJava component&lt;/P&gt; 
&lt;PRE&gt;String[] cols = { "This","is","test" };
context.SrcCols = cols;&lt;/PRE&gt; 
&lt;P&gt;I am accessing this context variable in tJavarow&lt;/P&gt; 
&lt;PRE&gt;String[] Cols = (String[])context.SrcCols;&lt;/PRE&gt; 
&lt;P&gt;but while running its giving the following error.&lt;/P&gt; 
&lt;P&gt;java.lang.ClassCastException: java.lang.String cannot be cast to [Ljava.lang.String;&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;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 05 Jun 2017 08:02:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248504#M33339</guid>
      <dc:creator>TomG1</dc:creator>
      <dc:date>2017-06-05T08:02:34Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248505#M33340</link>
      <description>&lt;P&gt;Hello Tom,&lt;/P&gt;&lt;P&gt;Did you get any solution to make it work in BigData Spark Job? we tried to implement the same and found this artilce with the same error what we are getting.&lt;/P&gt;&lt;P&gt;Please suggest.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 19 Dec 2017 16:21:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248505#M33340</guid>
      <dc:creator>Anil3</dc:creator>
      <dc:date>2017-12-19T16:21:29Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248506#M33341</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Currently, there is no access for "globalMap" in Spark Batch mode. This is due to a different implementation of Spark Batch compared to DI. You will only be able to&amp;nbsp;accomplish this with standard DI jobs.&lt;/P&gt;</description>
      <pubDate>Tue, 19 Dec 2017 17:45:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248506#M33341</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-12-19T17:45:12Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248507#M33342</link>
      <description>&lt;P&gt;This feature is not available in talend spark jobs.&lt;/P&gt;&lt;P&gt;We have raised a ticket to talend support and they mentioned that it is a limitation in talend big data job.&lt;/P&gt;&lt;P&gt;I don't know if this feature is available in talend latest version&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 05 Feb 2018 09:57:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248507#M33342</guid>
      <dc:creator>TomG1</dc:creator>
      <dc:date>2018-02-05T09:57:22Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248508#M33343</link>
      <description>&lt;P&gt;I need a globalmap or an alternative to this in spark jobs. Any ideas?&lt;/P&gt;</description>
      <pubDate>Sat, 14 Apr 2018 23:07:45 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248508#M33343</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-04-14T23:07:45Z</dc:date>
    </item>
    <item>
      <title>Re: globalMap.get() is not working</title>
      <link>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248509#M33344</link>
      <description>&lt;P&gt;Hello Guys, I opened a ticket with Talend and Jack from talend already responded to this thread.. So we went and tried something different&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;--&amp;gt; Create context variable solution like TOM suggested.&lt;/P&gt;
&lt;P&gt;--&amp;gt; Instead of usting tJavaRow, use tJava then&amp;nbsp;you will not get the casting error.&lt;/P&gt;
&lt;P&gt;--&amp;gt;&amp;nbsp;your job is somewaht like source data component --&amp;gt; Row (Main)&amp;nbsp;--&amp;gt; tJava&lt;/P&gt;
&lt;P&gt;--&amp;gt; I know tJava we should not use for main flow however Spark dataframe processing is different than actual main row flow in other talend jobs.&lt;/P&gt;
&lt;P&gt;--&amp;gt; with this solution we are able to make Spark job work but we couldn't take this solution to production as we are not convinced to use tJava like this.&lt;/P&gt;</description>
      <pubDate>Sun, 15 Apr 2018 18:52:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/globalMap-get-is-not-working/m-p/2248509#M33344</guid>
      <dc:creator>Anil3</dc:creator>
      <dc:date>2018-04-15T18:52:12Z</dc:date>
    </item>
  </channel>
</rss>

