CREATE TABLE #tab(start DATETIME, [end] DATETIME); INSER...

0

Please login or register to vote for this query.

(click on this box to dismiss)

Japanese Language Meta

Q&A about the site for students, teachers, and linguists wanting to discuss the finer points of the Japanese language

CREATE TABLE #tab(start DATETIME, [end] DATETIME);

INSERT INTO #tab
VALUES ('2015-11-01 10:00:00', '2015-11-02 12:00:00'),
('2015-11-01 10:00:00', '2015-11-03 12:00:00');

SELECT * 
FROM #tab
WHERE DATEDIFF(d, [start], [end]) = -1

Enter Parameters

Options:
Switch to main site
loading Hold tight while we fetch your results