how to use getdate in sql code example
Example 1: get current date sql
SELECT getdate(); -- Get Current date in SQL Server
Example 2: sql DATE = GETDATE()
CAST(GETDATE() AS DATE)
SELECT getdate(); -- Get Current date in SQL Server
CAST(GETDATE() AS DATE)