Answers for "date in sql server"

SQL
3

sql server current date

GETDATE()
Posted by: Guest on April-07-2020
0

DATE IN SQL

SELECT * FROM Orders WHERE OrderDate='2008-11-11'
Posted by: Guest on May-17-2021
0

sql server date field syntax

DATE - format YYYY-MM-DD
Posted by: Guest on October-14-2020
0

how to query date in sql server

select  *
from events
where event_date between '2020-01-01' and '2020-01-31';

-- can include time by specifying in YYYY-MM-DD hh:mm:ss format:
select  *
from events
where event_date between '2020-01-01 12:00:00' and '2020-01-01 23:30:00';
Posted by: Guest on September-20-2021

Code answers related to "SQL"

Browse Popular Code Answers by Language