<?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: how to compare date in talend in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/how-to-compare-date-in-talend/m-p/2367377#M130761</link>
    <description>Hi Shailendra,&lt;BR /&gt;step 1. Take lookup start date&lt;BR /&gt;step 2. do increment in loop till end date&lt;BR /&gt;step 3. check whether date is equivalent to input date or not&lt;BR /&gt;Tjava&lt;BR /&gt;long l =TalendDate.diffDate(end_date, start_date);&lt;BR /&gt;globalMap.put("iterate", l);&lt;BR /&gt;tLoop:&lt;BR /&gt;select : for&lt;BR /&gt;from : 0&lt;BR /&gt;to: (Long)globalMap.get("iterate")&lt;BR /&gt;step:1&lt;BR /&gt;tjava:&lt;BR /&gt;context.date =&lt;BR /&gt;TalendDate.addDate(context.start_date,"dd-MM-yyyy",((Integer)globalMap.get("tLoop_1_CURRENT_VALUE")),"DD");&lt;BR /&gt;System.out.println("DATE " + context.date);&lt;BR /&gt;TalendDate.compareDate(end_date, start_date,"dd-MM-yyyy")==0 ? Match : not match</description>
    <pubDate>Wed, 25 Sep 2013 10:29:41 GMT</pubDate>
    <dc:creator>nara1</dc:creator>
    <dc:date>2013-09-25T10:29:41Z</dc:date>
    <item>
      <title>how to compare date in talend</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-compare-date-in-talend/m-p/2367375#M130759</link>
      <description>hi,
&lt;BR /&gt;I have a input date(As KEY) and a lookup file 
&lt;BR /&gt;the lookup file has two colomn start_date and end_date on the basis of these two colomn 
&lt;BR /&gt;we have to update a,b and c
&lt;BR /&gt;THE senario is like this if my input date fall on the range of these two colmn's of lookup file we have to update a,b and c
&lt;BR /&gt;input date :28-07-2003
&lt;BR /&gt;lokup file:
&lt;BR /&gt;start date end date a b c
&lt;BR /&gt;28-06-2003 25-07-2003 200307 3 2003
&lt;BR /&gt;01-01-2010 29-01-2010 201001 1 2010
&lt;BR /&gt;26-09-2015 30-10-2015 201510 4 2015
&lt;BR /&gt;28-03-2009 24-04-2009 200904 2 2009
&lt;BR /&gt;
&lt;BR /&gt;how could i do this please give the solution 
&lt;BR /&gt;thank you in advance.
&lt;BR /&gt;kind regards
&lt;BR /&gt;Shailendra s.</description>
      <pubDate>Tue, 24 Sep 2013 13:36:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-compare-date-in-talend/m-p/2367375#M130759</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-09-24T13:36:54Z</dc:date>
    </item>
    <item>
      <title>Re: how to compare date in talend</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-compare-date-in-talend/m-p/2367376#M130760</link>
      <description>Hi Shailendra,
&lt;BR /&gt;you can use the tIntervalMatch component to lookup the date in the ranges (check the help-file for more info).
&lt;BR /&gt;regards,
&lt;BR /&gt;Walter.</description>
      <pubDate>Tue, 24 Sep 2013 22:29:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-compare-date-in-talend/m-p/2367376#M130760</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2013-09-24T22:29:03Z</dc:date>
    </item>
    <item>
      <title>Re: how to compare date in talend</title>
      <link>https://community.qlik.com/t5/Talend-Studio/how-to-compare-date-in-talend/m-p/2367377#M130761</link>
      <description>Hi Shailendra,&lt;BR /&gt;step 1. Take lookup start date&lt;BR /&gt;step 2. do increment in loop till end date&lt;BR /&gt;step 3. check whether date is equivalent to input date or not&lt;BR /&gt;Tjava&lt;BR /&gt;long l =TalendDate.diffDate(end_date, start_date);&lt;BR /&gt;globalMap.put("iterate", l);&lt;BR /&gt;tLoop:&lt;BR /&gt;select : for&lt;BR /&gt;from : 0&lt;BR /&gt;to: (Long)globalMap.get("iterate")&lt;BR /&gt;step:1&lt;BR /&gt;tjava:&lt;BR /&gt;context.date =&lt;BR /&gt;TalendDate.addDate(context.start_date,"dd-MM-yyyy",((Integer)globalMap.get("tLoop_1_CURRENT_VALUE")),"DD");&lt;BR /&gt;System.out.println("DATE " + context.date);&lt;BR /&gt;TalendDate.compareDate(end_date, start_date,"dd-MM-yyyy")==0 ? Match : not match</description>
      <pubDate>Wed, 25 Sep 2013 10:29:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/how-to-compare-date-in-talend/m-p/2367377#M130761</guid>
      <dc:creator>nara1</dc:creator>
      <dc:date>2013-09-25T10:29:41Z</dc:date>
    </item>
  </channel>
</rss>

