How to change the date format in SQL Server?
186
15-Oct-2024
Updated on 15-Oct-2024
Ashutosh Kumar Verma
15-Oct-2024In SQL Server, you can use the
FORMAT
function orCONVERT
function to change the Date format. Some of them are given below,Sample SQL Table: ‘Employees’ with the columns “EmpId, EmpName, CreationDate, Gender, Salary”
Example-
Using FORMAT()
Using CONVERT()
1.
2.