title: Batch Script: Identifying the latest file with incrementing file extension
body: <p>Can someone help me with handling the specific scenario explained below using windows batch script.</p>
  
  <p>We have a shared folder, which is used by a third party application tool (OBIEE) as a version controlled folder. In this folder the tool creates backup files with incrementing extension numbers.</p>
  
  <p><strong>For example</strong>: If we have a code file <strong><code>Projects.rpd</code></strong>, the first time we checkout this file, the tool creates <strong><code>Projects.000</code></strong> as a backup file. The next time it will be <code>Projects.001</code>, then <code>Projects.002</code> and so on.</p>
  
  <p>In the batch script, I need to get the file name of the latest backup file. In this example, <code>Projects.002</code></p>
  
  <p>I cannot go for the file with the latest timestamp, since the latest backup (<code>Projects.002</code>), the latest code file (<code>Projects.rpd</code>) and another control file will always have the same timestamp.</p>
  
  <p><strong>How can I identify the latest backup file in this scenario</strong>?</p>