<?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: CSV to MongoDB - XML-Tree problem in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/CSV-to-MongoDB-XML-Tree-problem/m-p/2361912#M126159</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you please show me the tMap component. I am also trying to create a nested document, but loop element is not creating a array, it is simply creating a sub element.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 03 Jul 2018 06:48:10 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2018-07-03T06:48:10Z</dc:date>
    <item>
      <title>CSV to MongoDB - XML-Tree problem</title>
      <link>https://community.qlik.com/t5/Talend-Studio/CSV-to-MongoDB-XML-Tree-problem/m-p/2361910#M126157</link>
      <description>&lt;P&gt;Hi Community!&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I have a really small problem with loading my structured csv to a MongoDB and &amp;nbsp;achieving the right format.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;STRONG&gt;What I currently have:&lt;/STRONG&gt;&lt;/P&gt; 
&lt;P&gt;My Talend process loops through a directory of csvs, loads them, uses a tMap component to add some information, gives it to a tMongoDBOutput.&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="mongo1.PNG" style="width: 907px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009Lr0j.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/143114i4C07F36DE1CD3B59/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009Lr0j.png" alt="0683p000009Lr0j.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;The input data is structured like like this:&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mongo3.PNG" style="width: 673px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009Lqz9.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/139558iDA7F8FAABCB5CE73/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009Lqz9.png" alt="0683p000009Lqz9.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;The columns "info", "sensorbasis" and "filename" are added within the tMap component and come either user input into a context variable, or (the filename) from the tFileList component.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;STRONG&gt;What I want to achieve:&lt;/STRONG&gt;&lt;/P&gt; 
&lt;P&gt;In the MongoDB there is a database called "mobidic" and a collection called "sensordata". I want to load all information from the CSVs to this exact collection, but, in a very specific structure that we need to work with at later stages. The format should look like this:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt; 
&lt;P&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mongo2.PNG" style="width: 302px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009Lqzb.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/131705iB26A992187855386/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009Lqzb.png" alt="0683p000009Lqzb.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;So basically, the result should be grouped by the fixed information, such as "sensorbasis", "info" and "filename", but the other columns should be in an array within the object "measurements". I understand, that I somehow have to set something as group, and something as a looping element.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;&lt;STRONG&gt;This is what I have achieved so far:&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt; 
&lt;P&gt;Data is loaded to the MongoDB. I have configured the tMongoDBOut component, but not as intended:&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="mongo4.PNG" style="width: 439px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009Lr2e.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/137045i0B61909E999A1FA6/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009Lr2e.png" alt="0683p000009Lr2e.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;And this is how the json tree within the component looks like:&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="mongo5.PNG" style="width: 764px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009LqvZ.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/153879i1CB8B9E21CF77BE2/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009LqvZ.png" alt="0683p000009LqvZ.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;What am I missing? I have searched through the board and did find some posts regarding the same challenge, but none of them brought me any further.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;I hope somebody here can give me a hint on what I am missing.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Tanks in advance!&lt;/P&gt; 
&lt;P&gt;Freddy&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 09:14:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/CSV-to-MongoDB-XML-Tree-problem/m-p/2361910#M126157</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2024-11-16T09:14:20Z</dc:date>
    </item>
    <item>
      <title>Re: CSV to MongoDB - XML-Tree problem</title>
      <link>https://community.qlik.com/t5/Talend-Studio/CSV-to-MongoDB-XML-Tree-problem/m-p/2361911#M126158</link>
      <description>&lt;P&gt;Nevermind. As long as Talend does not know what column to group by, I definitely won't be able to get the grouping I want.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Therefore, this is my working design now:&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="mongo6.PNG" style="width: 807px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009LrC6.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/148767i11796617567899F7/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009LrC6.png" alt="0683p000009LrC6.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;SPAN class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Mongo7.PNG" style="width: 764px;"&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0683p000009LrCe.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/129545i576A427640728ACB/image-size/large?v=v2&amp;amp;px=999" role="button" title="0683p000009LrCe.png" alt="0683p000009LrCe.png" /&gt;&lt;/span&gt;&lt;/SPAN&gt;&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Result is as intended.&lt;/P&gt; 
&lt;P&gt;&amp;nbsp;&lt;/P&gt; 
&lt;P&gt;Closed.&lt;/P&gt;</description>
      <pubDate>Mon, 02 Oct 2017 07:56:01 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/CSV-to-MongoDB-XML-Tree-problem/m-p/2361911#M126158</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-10-02T07:56:01Z</dc:date>
    </item>
    <item>
      <title>Re: CSV to MongoDB - XML-Tree problem</title>
      <link>https://community.qlik.com/t5/Talend-Studio/CSV-to-MongoDB-XML-Tree-problem/m-p/2361912#M126159</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Could you please show me the tMap component. I am also trying to create a nested document, but loop element is not creating a array, it is simply creating a sub element.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 03 Jul 2018 06:48:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/CSV-to-MongoDB-XML-Tree-problem/m-p/2361912#M126159</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2018-07-03T06:48:10Z</dc:date>
    </item>
  </channel>
</rss>

