<?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: tWriteJsonField auto remove '[' if the group has only one item in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/tWriteJsonField-auto-remove-if-the-group-has-only-one-item/m-p/2213315#M10616</link>
    <description>&lt;P&gt;Hi all,&lt;/P&gt; 
&lt;P&gt;To work arround, I use a tMap to replace the string as follow:&lt;/P&gt; 
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; row2.request.replace("\"items\":{", "\"items\":[{").replace("}}}", "}}]}")&lt;/P&gt; 
&lt;P&gt;It work fine for me, but I believe this may be a bug (correct me if it is not)&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture2.PNG" style="width: 719px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M93v.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/143722iD0F972E3E3CD845B/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M93v.png" alt="0683p000009M93v.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M92x.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/152746iFEAE184BEF19E8EE/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M92x.png" alt="0683p000009M92x.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 25 Feb 2020 08:44:27 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2020-02-25T08:44:27Z</dc:date>
    <item>
      <title>tWriteJsonField auto remove '[' if the group has only one item</title>
      <link>https://community.qlik.com/t5/Talend-Studio/tWriteJsonField-auto-remove-if-the-group-has-only-one-item/m-p/2213314#M10615</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I use tWriteJsonField to generate json from my database, its content is like this&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="Capture.PNG" style="width: 788px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M98k.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/153386i2E029D030F6C2989/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M98k.png" alt="0683p000009M98k.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;When I run the job, if the group contains more than 1 element, the '[' and the ']' appear to group the items, but if there is only one item in the group, they display as normal item without '[' and ']'.&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 759px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M96B.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/138813iD5F0EC3E7DC580CD/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M96B.png" alt="0683p000009M96B.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;Because the next usage require this is a collection, so that the [ and ] is important to me. How can I keep them even if there is only one item in the group?&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Thanks&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 03:11:06 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/tWriteJsonField-auto-remove-if-the-group-has-only-one-item/m-p/2213314#M10615</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-11-16T03:11:06Z</dc:date>
    </item>
    <item>
      <title>Re: tWriteJsonField auto remove '[' if the group has only one item</title>
      <link>https://community.qlik.com/t5/Talend-Studio/tWriteJsonField-auto-remove-if-the-group-has-only-one-item/m-p/2213315#M10616</link>
      <description>&lt;P&gt;Hi all,&lt;/P&gt; 
&lt;P&gt;To work arround, I use a tMap to replace the string as follow:&lt;/P&gt; 
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; row2.request.replace("\"items\":{", "\"items\":[{").replace("}}}", "}}]}")&lt;/P&gt; 
&lt;P&gt;It work fine for me, but I believe this may be a bug (correct me if it is not)&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture2.PNG" style="width: 719px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M93v.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/143722iD0F972E3E3CD845B/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M93v.png" alt="0683p000009M93v.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.PNG" style="width: 999px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009M92x.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/152746iFEAE184BEF19E8EE/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009M92x.png" alt="0683p000009M92x.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 25 Feb 2020 08:44:27 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/tWriteJsonField-auto-remove-if-the-group-has-only-one-item/m-p/2213315#M10616</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-02-25T08:44:27Z</dc:date>
    </item>
  </channel>
</rss>

