About 190,000 results
Open links in new tab
  1. Difference of two date time in sql server - Stack Overflow

    Jan 22, 2010 · 20 I can mention four important functions of MS SQL Server that can be very useful: 1) The function DATEDIFF () is responsible to calculate differences between two dates, …

  2. SQL time difference between two dates result in hh:mm:ss

    DateDifference 1 73:12:30 It's also easier to read the result if you add padding so the format is always hh:mm:ss. For example, here's how you would do that in SQL Server 2012 or later:

  3. Time difference with hours, minutes and seconds in SQL Server

    Jan 2, 2017 · Time difference with hours, minutes and seconds in SQL Server Asked 8 years, 11 months ago Modified 2 years, 1 month ago Viewed 31k times

  4. sql server - datediff rounding - Stack Overflow

    I have a db table in SQL Server which contains a start date for a project. On a web status page I want to show how many days/weeks/months the project has run, the units depending on the …

  5. sql server - Calculate exact date difference in years using SQL

    sql sql-server datediff edited Apr 18, 2014 at 16:47 user330315 asked Apr 17, 2014 at 23:59

  6. sql server - DATEDIFF Rounding - Database Administrators Stack …

    Aug 27, 2024 · No rounding occurs in this case because the zero maps to an exact date value and the strings are all exactly representable. 3. MishMash = DATEDIFF(DAY, …

  7. sql server 2008 - DATEADD (MONTH, DATEDIFF (MONTH, 0, …

    Jul 26, 2012 · DATEDIFF(MONTH, 0, '2-14-2015') --returns month. 0 is for 1/1/1900, and getdate is the current date --(i used a set date bc dates will change as this post gets older). result: …

  8. sql server - Calculating number of full months between two dates …

    SELECT DATEDIFF(MONTH, '2009-04-16', '2009-05-15') but instead of giving me full months between the two date, it gives me the difference of the month part, i.e. anyone know how to …

  9. sql - Datediff function between a date column and current date?

    How can I correctly calculate the difference in days or years between a date column and the current date? typically would use where date_diff('day, date_column1, date_column2) as …

  10. sql - Datediff between 2 columns in same table - Stack Overflow

    Datediff between 2 columns in same table Asked 12 years, 2 months ago Modified 3 years, 4 months ago Viewed 48k times