<?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: Issue while rounding value in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307778#M79177</link>
    <description>&lt;P&gt;it is not working :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;context.nombre_ligne = (int)java.lang.Math.ceil(((Integer)globalMap.get("tFileRowCount_2_COUNT")/4));&lt;/P&gt;&lt;P&gt;System.out.println(context.nombre_ligne);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;10records / 4 =&amp;gt; i have result =&amp;gt; 2&lt;/P&gt;&lt;P&gt;it should have been 3.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;RA&lt;/P&gt;</description>
    <pubDate>Fri, 17 Jun 2022 09:56:40 GMT</pubDate>
    <dc:creator>RA6</dc:creator>
    <dc:date>2022-06-17T09:56:40Z</dc:date>
    <item>
      <title>Issue while rounding value</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307776#M79175</link>
      <description>&lt;P&gt;Hello guys,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have an input file delimited and i need to divide the number of records (tFileRowCount_2_COUNT) by 4 in a tjava component.&lt;/P&gt;&lt;P&gt;I need the below expected result. Can someone help on this please?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0695b00000SprQQAAZ.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/138806i44EC014961DACF51/image-size/large?v=v2&amp;amp;px=999" role="button" title="0695b00000SprQQAAZ.png" alt="0695b00000SprQQAAZ.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0695b00000SprPrAAJ.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/136358i2745886BB3E738C4/image-size/large?v=v2&amp;amp;px=999" role="button" title="0695b00000SprPrAAJ.png" alt="0695b00000SprPrAAJ.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note: my context variable (context.nombre_ligne) is of type integer.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;RA&lt;/P&gt;</description>
      <pubDate>Fri, 15 Nov 2024 22:49:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307776#M79175</guid>
      <dc:creator>RA6</dc:creator>
      <dc:date>2024-11-15T22:49:10Z</dc:date>
    </item>
    <item>
      <title>Re: Issue while rounding value</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307777#M79176</link>
      <description>&lt;P&gt;Hi @Rohit Aftab​&amp;nbsp;, if you want to round up, try the method Math.ceil() instead of Math.round().&lt;/P&gt;&lt;P&gt;Send me love and kudos&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jun 2022 09:47:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307777#M79176</guid>
      <dc:creator>gjeremy1617088143</dc:creator>
      <dc:date>2022-06-17T09:47:41Z</dc:date>
    </item>
    <item>
      <title>Re: Issue while rounding value</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307778#M79177</link>
      <description>&lt;P&gt;it is not working :&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;context.nombre_ligne = (int)java.lang.Math.ceil(((Integer)globalMap.get("tFileRowCount_2_COUNT")/4));&lt;/P&gt;&lt;P&gt;System.out.println(context.nombre_ligne);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;10records / 4 =&amp;gt; i have result =&amp;gt; 2&lt;/P&gt;&lt;P&gt;it should have been 3.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Best regards,&lt;/P&gt;&lt;P&gt;RA&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jun 2022 09:56:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307778#M79177</guid>
      <dc:creator>RA6</dc:creator>
      <dc:date>2022-06-17T09:56:40Z</dc:date>
    </item>
    <item>
      <title>Re: Issue while rounding value</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307779#M79178</link>
      <description>&lt;P&gt;cast your integer as a double and it will work&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 17 Jun 2022 10:09:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307779#M79178</guid>
      <dc:creator>gjeremy1617088143</dc:creator>
      <dc:date>2022-06-17T10:09:20Z</dc:date>
    </item>
    <item>
      <title>Re: Issue while rounding value</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307780#M79179</link>
      <description>&lt;P&gt;Hi @Rohit Aftab​,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;B&gt;(int) Math.ceil(row7.records/4.0)&lt;/B&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;context.nombre_ligne = (int) Math.ceil(((Integer)globalMap.get("tFileRowCount_2_COUNT")/4.0));&lt;/P&gt;&lt;P&gt;System.out.println(context.nombre_ligne);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;&lt;span class="lia-unicode-emoji" title=":face_with_medical_mask:"&gt;😷&lt;/span&gt; &lt;/P&gt;</description>
      <pubDate>Fri, 17 Jun 2022 16:50:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Issue-while-rounding-value/m-p/2307780#M79179</guid>
      <dc:creator>InfoCraft</dc:creator>
      <dc:date>2022-06-17T16:50:52Z</dc:date>
    </item>
  </channel>
</rss>

