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

    Jan 22, 2010 · Is there any way to take the difference between two datetime in sql server? For example, my dates are 2010-01-22 15:29:55.090 2010-01-22 15:30:09.153 So, the result …

  2. sql - DATEDIFF function in Oracle - Stack Overflow

    Feb 9, 2015 · I need to use Oracle but DATEDIFF function doesn't work in Oracle DB. How to write the following code in Oracle? I saw some examples using INTERVAL or TRUNC. …

  3. sql server - DateDiff () Hours and Minutes? - Stack Overflow

    Mar 7, 2016 · Closed 9 years ago. This question have been asked many times but i cannot find any easy answers on how to get hours and minutes from a datediff().

  4. t sql - How to calculate difference in hours (decimal) between two ...

    I have to calculate the difference in hours (decimal type) between two dates in SQL Server 2008. I couldn't find any useful technique to convert datetime to decimal with 'CONVERT' on MSDN. …

  5. Calculate exact date difference in years using SQL

    I receive reports in which the data is ETL to the DB automatically. I extract and transform some of that data to load it somewhere else. One thing I need to do is a DATEDIFF but the year needs …

  6. Diferença entre duas datas em dias, horas, minutos e segundos

    Jun 7, 2015 · Problema: Como realizar a subtração entre duas datas e retornar o valor em Dias, Horas, Minutos e Segundos em uma consulta SQL com SQL Server 2014? Exemplo: Dados: …

  7. Include Start Date and the End Date in DateDiff function

    DATEDIFF(DAY, '8/4/2014', '8/5/2014') +1 You need to add 1 to the DATEDIFF function and it will work as you want. Also to note that: DATEDIFF Returns the count (signed integer) of the …

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

    The DateDiff function returns how many seconds, months, years - whatever interval you specify between the first date (here 0) and the second date (here the current date).

  9. How to calculate DATE Difference in PostgreSQL? - Stack Overflow

    Here I need to calculate the difference of the two dates in the PostgreSQL. Like we do in SQL Server its much easier. DATEDIFF(Day, MIN(joindate), MAX(joindate)) AS DateDifference; I …

  10. How do you handle NULLs in a DATEDIFF comparison?

    Why use datediff instead of just comparing the two dates? Doesn't that just require extra processing time?