<?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: Date Subtraction for Month Start Dates in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328714#M97974</link>
    <description>&lt;P&gt;It worked, thank you @Vaishnavi Khandelwal​&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 05 Mar 2021 02:58:40 GMT</pubDate>
    <dc:creator>rajesh90</dc:creator>
    <dc:date>2021-03-05T02:58:40Z</dc:date>
    <item>
      <title>Date Subtraction for Month Start Dates</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328710#M97970</link>
      <description>&lt;P&gt;Hello Everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In my code, whenever I pick source files I need to pick T-1 date files. So when I subtract the month starting date with -1 using the below expression it results to incorrect date value,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Expression :&lt;/P&gt;&lt;P&gt;context.Load_Date=String.valueOf(Integer.parseInt(TalendDate.getDate("YYYYMMDD"))-1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example :&lt;/P&gt;&lt;P&gt;Input Date = 20210101&lt;/P&gt;&lt;P&gt;Output Date Value received after subtracting 1 = 20210200&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The format of the date is YYYYMMDD. &lt;/P&gt;&lt;P&gt;Can you help with a solution to fix this issue.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Feb 2021 16:12:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328710#M97970</guid>
      <dc:creator>rajesh90</dc:creator>
      <dc:date>2021-02-26T16:12:56Z</dc:date>
    </item>
    <item>
      <title>Re: Date Subtraction for Month Start Dates</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328711#M97971</link>
      <description>&lt;P&gt;Hello @Rajesh L R​&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could you please confirm if you mean "T-1" as the previous day?&lt;/P&gt;&lt;P&gt;Please provide us the expected output, so that we can check accordingly.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vaishnavi&lt;/P&gt;</description>
      <pubDate>Fri, 26 Feb 2021 16:44:50 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328711#M97971</guid>
      <dc:creator>prg</dc:creator>
      <dc:date>2021-02-26T16:44:50Z</dc:date>
    </item>
    <item>
      <title>Re: Date Subtraction for Month Start Dates</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328712#M97972</link>
      <description>&lt;P&gt;Hi @Vaishnavi Khandelwal​&amp;nbsp;, &lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Yes T-1 is previous day. &lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Expression :&lt;/P&gt;&lt;P&gt;context.Load_Date=String.valueOf(Integer.parseInt(TalendDate.getDate("YYYYMMDD"))-1);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Current Data :&lt;/P&gt;&lt;P&gt;Input Date : 20210301&lt;/P&gt;&lt;P&gt;Output Date : &lt;B&gt;20210300&lt;/B&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Expected Data :&lt;/P&gt;&lt;P&gt;Input Date : 20210301&lt;/P&gt;&lt;P&gt;Output Date : &lt;B&gt;20210228&lt;/B&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Feb 2021 18:02:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328712#M97972</guid>
      <dc:creator>rajesh90</dc:creator>
      <dc:date>2021-02-26T18:02:17Z</dc:date>
    </item>
    <item>
      <title>Re: Date Subtraction for Month Start Dates</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328713#M97973</link>
      <description>&lt;P&gt;Hello @Rajesh L R​&amp;nbsp;,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please try using the below logic;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Date a=TalendDate.addDate(TalendDate.getCurrentDate(),-1,"dd");&lt;/P&gt;&lt;P&gt;System.out.println(TalendDate.formatDate("yyyyMMdd", a));&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="0693p00000BZQp6AAH.png"&gt;&lt;img src="https://community.qlik.com/t5/image/serverpage/image-id/148486i7B7CE1536189805D/image-size/large?v=v2&amp;amp;px=999" role="button" title="0693p00000BZQp6AAH.png" alt="0693p00000BZQp6AAH.png" /&gt;&lt;/span&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please let us know if it helps. If yes, mark it resolved (Kudos also accepted).&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Vaishnavi&lt;/P&gt;</description>
      <pubDate>Mon, 01 Mar 2021 17:21:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328713#M97973</guid>
      <dc:creator>prg</dc:creator>
      <dc:date>2021-03-01T17:21:33Z</dc:date>
    </item>
    <item>
      <title>Re: Date Subtraction for Month Start Dates</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328714#M97974</link>
      <description>&lt;P&gt;It worked, thank you @Vaishnavi Khandelwal​&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 05 Mar 2021 02:58:40 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Date-Subtraction-for-Month-Start-Dates/m-p/2328714#M97974</guid>
      <dc:creator>rajesh90</dc:creator>
      <dc:date>2021-03-05T02:58:40Z</dc:date>
    </item>
  </channel>
</rss>

