title: Greatest of multiple values in SQL Server
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/1972051/sql-server-equivalent-to-oracle-least">SQL Server equivalent to Oracle LEAST?</a><br>
    <a href="https://stackoverflow.com/questions/4725823/function-in-sql-server-2008-similar-to-greatest-in-mysql">Function in SQL Server 2008 similar to GREATEST in mysql?</a>  </p>
  </blockquote>
  
  
  
  <p>i am trying to find a SQL Server equivalent of oracle's "GREATEST" function.</p>
  
  <p>something that would return the largest (in this case timestamp) from a list of values given</p>
  
  <p>example: <code>greatest(timestamp1, temestamp2, timestamp3)</code>  would return the most current date.</p>
  
  <p>is there something like this in SQL Server i can use?</p>
  
  <p>Thanks!</p>