TSQL last second of day


/ Published in: SQL
Save to your folder(s)

Returns the last second of the day for a given datetime value (@date).


Copy this code and paste it in your HTML
  1. DATEADD(s, -1, DATEADD(d, 1, DATEADD(d, DATEDIFF(d, 0, @DATE), 0)))

Report this snippet


Comments


You need to login to view comments.