<?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: Delete files older than 90 days in Talend Studio</title>
    <link>https://community.qlik.com/t5/Talend-Studio/Delete-files-older-than-90-days/m-p/2302582#M74551</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;Please try to design your work flow like:&lt;/P&gt;&lt;P&gt;tFileList---iterate-- &amp;gt; tFileProperties ---main---&amp;gt;tMap-------main---&amp;gt;tfileDelete&lt;/P&gt;&lt;P&gt;On tMap schema editor, you can use a condition to check mtime in expression &lt;/P&gt;&lt;P&gt;((TalendDate.getCurrentDate()).getTime() - (Long)row1.mtime) &amp;gt; (90 * 24 * 3600000) to delete files based on above condition. &lt;/P&gt;&lt;P&gt;Let us know if it works for you.&lt;/P&gt;&lt;P&gt;Best regards&lt;/P&gt;&lt;P&gt;Sabrina&lt;/P&gt;</description>
    <pubDate>Wed, 04 Nov 2020 09:21:35 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2020-11-04T09:21:35Z</dc:date>
    <item>
      <title>Delete files older than 90 days</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Delete-files-older-than-90-days/m-p/2302581#M74550</link>
      <description>&lt;P&gt;Hi everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to delete the files from an archive folder which are older than 90 days. My job design is as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;tfilelist --&amp;gt; tfileproperties --&amp;gt; tmap --&amp;gt; tfilterrow --&amp;gt; tfiledelete.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in tmap, I'm using the diffdate function to get the difference between the current date and the mtime_string in days ("dd"). After this I need to put the logic to delete all the files which are older than 90 days, which I'm not able to. Please help!! &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 28 Oct 2020 09:29:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Delete-files-older-than-90-days/m-p/2302581#M74550</guid>
      <dc:creator>RRasti1603876642</dc:creator>
      <dc:date>2020-10-28T09:29:24Z</dc:date>
    </item>
    <item>
      <title>Re: Delete files older than 90 days</title>
      <link>https://community.qlik.com/t5/Talend-Studio/Delete-files-older-than-90-days/m-p/2302582#M74551</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;Please try to design your work flow like:&lt;/P&gt;&lt;P&gt;tFileList---iterate-- &amp;gt; tFileProperties ---main---&amp;gt;tMap-------main---&amp;gt;tfileDelete&lt;/P&gt;&lt;P&gt;On tMap schema editor, you can use a condition to check mtime in expression &lt;/P&gt;&lt;P&gt;((TalendDate.getCurrentDate()).getTime() - (Long)row1.mtime) &amp;gt; (90 * 24 * 3600000) to delete files based on above condition. &lt;/P&gt;&lt;P&gt;Let us know if it works for you.&lt;/P&gt;&lt;P&gt;Best regards&lt;/P&gt;&lt;P&gt;Sabrina&lt;/P&gt;</description>
      <pubDate>Wed, 04 Nov 2020 09:21:35 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Talend-Studio/Delete-files-older-than-90-days/m-p/2302582#M74551</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2020-11-04T09:21:35Z</dc:date>
    </item>
  </channel>
</rss>

