<?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: Can't parse JSON correctly in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300054#M72328</link>
    <description>I've written a tutorial on working with Facebook using Talend (to get Spotify data in this case) and I cover an example of dealing with JSON. You can download the example jobs to try this out. It is reasonably complicated, but if you work through it I think you should be able to extrapolate from it to find your solution. The tutorial is &lt;A href="http://www.rilhia.com/tutorials/using-talend-get-your-spotify-listening-history-facebook" target="_blank" rel="nofollow noopener noreferrer"&gt;here&lt;/A&gt;. The section on &amp;nbsp;getting data from a JSON String is titled "Extract data from JSON".</description>
    <pubDate>Wed, 14 Oct 2015 21:45:23 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2015-10-14T21:45:23Z</dc:date>
    <item>
      <title>Can't parse JSON correctly</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300052#M72326</link>
      <description>&lt;P&gt;I'm trying to automate some APIs. So I started from Google analytics one (I know that Talend has &amp;nbsp;a component for it, I just want to educate myself so that I can then jump to Facebook etc)&lt;BR /&gt;&lt;BR /&gt;Here is my Job:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Response from GA looks like this:&lt;/P&gt; 
&lt;PRE&gt;{"kind":"analytics#gaData",&lt;BR /&gt; "id":"",&lt;BR /&gt; "query":{"start-date":"2015-01-01","end-date":"2015-01-10","ids":"ga:1111111","dimensions":"ga:date,ga:medium,ga:browser","metrics":["ga:sessions","ga:bounces"],"start-index":1,"max-results":1000},"itemsPerPage":1000,"totalResults":156,"selfLink":"","profileInfo":{"profileId":"11111111","accountId":"111111","webPropertyId":"UA-1111111","internalWebPropertyId":"11111111","profileName":"aaaaaaaa","tableId":"ga:11111111"},"containsSampledData":false,"columnHeaders":[{"name":"ga:date","columnType":"DIMENSION","dataType":"STRING"},{"name":"ga:medium","columnType":"DIMENSION","dataType":"STRING"},{"name":"ga:browser","columnType":"DIMENSION","dataType":"STRING"},{"name":"ga:sessions","columnType":"METRIC","dataType":"INTEGER"},{"name":"ga:bounces","columnType":"METRIC","dataType":"INTEGER"}],"totalsForAllResults":{"ga:sessions":"907","ga:bounces":"480"},&lt;BR /&gt;&lt;BR /&gt;"rows":[["20150101","(none)","Chrome","3","2"],["20150101","(none)","Safari","2","1"],["20150101","organic","Chrome","9","4"]]}&lt;/PRE&gt; 
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;I specifically want to extract 'rows' part in columns.&lt;BR /&gt;I can&amp;nbsp;successfully&amp;nbsp;make it for the first object in the array:&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;But when I replace&amp;nbsp;"$.rows[0][1]" to "$.rows[][1]" &amp;nbsp;to iterate, I get nulls.&lt;BR /&gt;Any help will be&amp;nbsp;appreciated.&lt;BR /&gt;&lt;BR /&gt;Also. How can I save the result of my REST request into the file? tFileJSONoutput &amp;nbsp;adds some weird body object and I can't read anything from the file after that. Can I save plain text into txt?&lt;BR /&gt;&lt;BR /&gt;Thanks&lt;/P&gt;</description>
      <pubDate>Wed, 14 Oct 2015 13:11:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300052#M72326</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2015-10-14T13:11:38Z</dc:date>
    </item>
    <item>
      <title>Re: Can't parse JSON correctly</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300053#M72327</link>
      <description>Anyone who knows JSON components well? I would really appreciate your help. 
&lt;BR /&gt; 
&lt;BR /&gt;I'm using "jsonquerytool[dot]com" to validate my queries. And by using&amp;nbsp; 
&lt;BR /&gt; 
&lt;BLOCKQUOTE&gt;
  $.rows[Asterisk][0] 
&lt;/BLOCKQUOTE&gt; 
&lt;BR /&gt;I'm able to extract all the first elements in rows array. 
&lt;BR /&gt; 
&lt;BR /&gt;But how do I make it in Talend?</description>
      <pubDate>Wed, 14 Oct 2015 21:31:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300053#M72327</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2015-10-14T21:31:24Z</dc:date>
    </item>
    <item>
      <title>Re: Can't parse JSON correctly</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300054#M72328</link>
      <description>I've written a tutorial on working with Facebook using Talend (to get Spotify data in this case) and I cover an example of dealing with JSON. You can download the example jobs to try this out. It is reasonably complicated, but if you work through it I think you should be able to extrapolate from it to find your solution. The tutorial is &lt;A href="http://www.rilhia.com/tutorials/using-talend-get-your-spotify-listening-history-facebook" target="_blank" rel="nofollow noopener noreferrer"&gt;here&lt;/A&gt;. The section on &amp;nbsp;getting data from a JSON String is titled "Extract data from JSON".</description>
      <pubDate>Wed, 14 Oct 2015 21:45:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300054#M72328</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2015-10-14T21:45:23Z</dc:date>
    </item>
    <item>
      <title>Re: Can't parse JSON correctly</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300055#M72329</link>
      <description>&lt;B&gt;&lt;FONT color="#5b5b5d"&gt;&lt;FONT size="2"&gt;&lt;FONT face="Verdana," helvetica=""&gt;rhall_2.0 Thanks a lot! Definetly checking it out.&lt;BR /&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;/B&gt; 
&lt;BR /&gt;If anyone can help with my situaltion - That would be still good. How do I deal with array of arrays in Talend?</description>
      <pubDate>Wed, 14 Oct 2015 22:25:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300055#M72329</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2015-10-14T22:25:22Z</dc:date>
    </item>
    <item>
      <title>Re: Can't parse JSON correctly</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300056#M72330</link>
      <description>May it be connected with this issue:&lt;BR /&gt;&lt;BR /&gt;[dot]org/forum/viewtopic.php?id=38398</description>
      <pubDate>Wed, 14 Oct 2015 23:10:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Can-t-parse-JSON-correctly/m-p/2300056#M72330</guid>
      <dc:creator>_AnonymousUser</dc:creator>
      <dc:date>2015-10-14T23:10:25Z</dc:date>
    </item>
  </channel>
</rss>

