Answers for "today midnight SQL"

SQL
0

sql today at midnight

SELECT DATEADD(d, 0, DATEDIFF(d, 0, GETDATE()))
Posted by: Guest on February-08-2021
0

today midnight SQL

#Today midnight is same as the next day at 0000hrs
#today at 23:59:59
SELECT (CURDATE()+ INTERVAL 1 DAY - INTERVAL 1 SECOND); #return
#tomrrow at 0000hrs
# You can skip adding the timesamp
SELECT TIMEsTAMP(CURDATE()+ INTERVAL 1 DAY);
Posted by: Guest on March-25-2022

Code answers related to "SQL"

Browse Popular Code Answers by Language