26 May 2012

Get the dayname of current week using SQL with system function

For MS SQL Server 2005,

This query result with output of today's name of the day :
for example , sunday or monday etc.


SELECT { fn DAYNAME(GETDATE()) } AS Expr1

This is a system defined function , so you can use it to get the todays day .

(If you found this article useful then share with your friends.)

No comments: