<?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 Create array inside JSON in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323175#M93052</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt; 
&lt;P&gt;I created a JSON file using tWriteJSONfield.&lt;/P&gt; 
&lt;P&gt;Currently, I got the following format:&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;{&lt;BR /&gt;"url": "&lt;A href="http://google.com" target="_blank" rel="nofollow noopener noreferrer"&gt;http://google.com&lt;/A&gt;",&lt;BR /&gt;"findings": {&lt;BR /&gt;"id": "1",&lt;BR /&gt;"type": "1",&lt;BR /&gt;"sub_type": "7",&lt;BR /&gt;"cul": [],&lt;BR /&gt;"or": "3",&lt;BR /&gt;"date": "05-05-2015",&lt;BR /&gt;"num": []&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;and need the following ("findings" data should be inside an array):&lt;/P&gt; 
&lt;P&gt;{&lt;BR /&gt;"url": "&lt;A href="http://google.com" target="_blank" rel="nofollow noopener noreferrer"&gt;http://google.com&lt;/A&gt;",&lt;BR /&gt;"findings": &lt;STRONG&gt;[&lt;/STRONG&gt;{&lt;BR /&gt;"id": "1",&lt;BR /&gt;"type": "1",&lt;BR /&gt;"sub_type": "7",&lt;BR /&gt;"cul": [],&lt;BR /&gt;"or": "3",&lt;BR /&gt;"date": "05-05-2015",&lt;BR /&gt;"num": []&lt;BR /&gt;}&lt;STRONG&gt;]&lt;/STRONG&gt;&lt;BR /&gt;}&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;How can I do that?&lt;/P&gt; 
&lt;P&gt;Attached&amp;nbsp;is a screenshot of my Json&amp;nbsp;tree.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Thanks,&lt;/P&gt; 
&lt;P&gt;Emma&lt;/P&gt;</description>
    <pubDate>Tue, 20 Mar 2018 10:41:51 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-03-20T10:41:51Z</dc:date>
    <item>
      <title>Create array inside JSON</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323175#M93052</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt; 
&lt;P&gt;I created a JSON file using tWriteJSONfield.&lt;/P&gt; 
&lt;P&gt;Currently, I got the following format:&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;{&lt;BR /&gt;"url": "&lt;A href="http://google.com" target="_blank" rel="nofollow noopener noreferrer"&gt;http://google.com&lt;/A&gt;",&lt;BR /&gt;"findings": {&lt;BR /&gt;"id": "1",&lt;BR /&gt;"type": "1",&lt;BR /&gt;"sub_type": "7",&lt;BR /&gt;"cul": [],&lt;BR /&gt;"or": "3",&lt;BR /&gt;"date": "05-05-2015",&lt;BR /&gt;"num": []&lt;BR /&gt;}&lt;BR /&gt;}&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;and need the following ("findings" data should be inside an array):&lt;/P&gt; 
&lt;P&gt;{&lt;BR /&gt;"url": "&lt;A href="http://google.com" target="_blank" rel="nofollow noopener noreferrer"&gt;http://google.com&lt;/A&gt;",&lt;BR /&gt;"findings": &lt;STRONG&gt;[&lt;/STRONG&gt;{&lt;BR /&gt;"id": "1",&lt;BR /&gt;"type": "1",&lt;BR /&gt;"sub_type": "7",&lt;BR /&gt;"cul": [],&lt;BR /&gt;"or": "3",&lt;BR /&gt;"date": "05-05-2015",&lt;BR /&gt;"num": []&lt;BR /&gt;}&lt;STRONG&gt;]&lt;/STRONG&gt;&lt;BR /&gt;}&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;How can I do that?&lt;/P&gt; 
&lt;P&gt;Attached&amp;nbsp;is a screenshot of my Json&amp;nbsp;tree.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Thanks,&lt;/P&gt; 
&lt;P&gt;Emma&lt;/P&gt;</description>
      <pubDate>Tue, 20 Mar 2018 10:41:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323175#M93052</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-03-20T10:41:51Z</dc:date>
    </item>
    <item>
      <title>Re: Create array inside JSON</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323176#M93053</link>
      <description>&lt;P&gt;Take a look at this webpage:&amp;nbsp;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;A href="https://help.talend.com/reader/KxVIhxtXBBFymmkkWJ~O4Q/50PMKM8mz4A5fAL~FQcLHw?section=twritejsonfield_configuring_json_tree" target="_blank" rel="nofollow noopener noreferrer"&gt;https://help.talend.com/reader/KxVIhxtXBBFymmkkWJ~O4Q/50PMKM8mz4A5fAL~FQcLHw?section=twritejsonfield_configuring_json_tree&lt;/A&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Notice the&amp;nbsp;@class attribute and the "array" in the "static value" column? You need to make use of these. You will need to play around with this functionality until you "get it", but it is worth spending a few hours doing this to get it to sink in &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Mar 2018 11:11:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323176#M93053</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-03-20T11:11:04Z</dc:date>
    </item>
    <item>
      <title>Re: Create array inside JSON</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323177#M93054</link>
      <description>&lt;P&gt;Thank you,&lt;/P&gt;
&lt;P&gt;I defined "findings" as&amp;nbsp;@class&amp;nbsp; = array, and added the sub-element&amp;nbsp;"element" and defined it as "loop element", I managed to get "findings" as an array,&lt;/P&gt;
&lt;P&gt;But without the element names (id, type, sub_type, cul, or, date, num):&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;{&lt;BR /&gt;"url": "&lt;A href="http://xn--5dbdc6fk.net/" target="_blank" rel="nofollow noopener noreferrer"&gt;http:/&lt;/A&gt;/google.com",&lt;BR /&gt;"findings": [&lt;BR /&gt;"1",&lt;BR /&gt;"1",&lt;BR /&gt;"7",&lt;BR /&gt;[],&lt;BR /&gt;"3",&lt;BR /&gt;"05-05-2015",&lt;BR /&gt;null,&lt;BR /&gt;[]&lt;BR /&gt;]&lt;BR /&gt;}&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Do you know how to display&amp;nbsp;the&amp;nbsp;&lt;SPAN&gt;element names inside the array?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Thanks.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Mar 2018 12:46:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323177#M93054</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-03-20T12:46:57Z</dc:date>
    </item>
    <item>
      <title>Re: Create array inside JSON</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323178#M93055</link>
      <description>&lt;P&gt;OK, I have built the following dummy structure.....&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;PRE&gt;{"rootTag":{"newColumn1":"IH4IST","newColumn2":[{"newColumn3":"IqGyhp","newColumn4":"ULsg8G"}]}}&lt;/PRE&gt; 
&lt;P&gt;....using this configuration.....&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="json_demo.png" style="width: 773px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009Lt8Z.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/141571i30ED568640CC0A5A/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009Lt8Z.png" alt="0683p000009Lt8Z.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Basically, add an element called "element", assign it a class of object and add your fields to that element. That should do it.&lt;/P&gt;</description>
      <pubDate>Tue, 20 Mar 2018 13:03:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323178#M93055</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-03-20T13:03:48Z</dc:date>
    </item>
    <item>
      <title>Re: Create array inside JSON</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323179#M93056</link>
      <description>&lt;P&gt;Thank you, It works &lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009MACn.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/154443iC5B8CACEF3D12C6A/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009MACn.png" alt="0683p000009MACn.png" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 20 Mar 2018 13:16:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323179#M93056</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-03-20T13:16:43Z</dc:date>
    </item>
    <item>
      <title>Re: Create array inside JSON</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323180#M93057</link>
      <description>&lt;P&gt;&lt;A href="https://community.qlik.com/s/profile/005390000069RuGAAU"&gt;@rhall&lt;/A&gt;&amp;nbsp; Could you please let me know how to configure multiple array objects&lt;/P&gt; 
&lt;P&gt;my expected output is as below&lt;/P&gt; 
&lt;P&gt;{&lt;BR /&gt;"_id": "123",&lt;BR /&gt;"cabins": [&lt;BR /&gt;{&lt;BR /&gt;"cabin_Id": "12434",&lt;BR /&gt;"name": "Cabin 1"&lt;BR /&gt;},&lt;BR /&gt;{&lt;BR /&gt;"cabin_Id": "8765",&lt;BR /&gt;"name": "Cabin 3"&lt;BR /&gt;}&lt;BR /&gt;],&lt;BR /&gt;"country": "FR",&lt;BR /&gt;"departments": [&lt;BR /&gt;{&lt;BR /&gt;"dept_id": "123",&lt;BR /&gt;"name": "Computers"&lt;BR /&gt;},&lt;BR /&gt;{&lt;BR /&gt;"dept_id": "345",&lt;BR /&gt;"name": "arch"&lt;BR /&gt;}&lt;BR /&gt;]&lt;BR /&gt;}&lt;/P&gt;</description>
      <pubDate>Tue, 12 May 2020 23:00:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Create-array-inside-JSON/m-p/2323180#M93057</guid>
      <dc:creator>Gattuchaitanya</dc:creator>
      <dc:date>2020-05-12T23:00:50Z</dc:date>
    </item>
  </channel>
</rss>

