Today i got a requirement to convert my date into day month and year format. I have used below query for that.
This kind of format mainly we are going to use in the PIVOT Queries as well as dynamics queries of SQL Server.
Output of the
18 Dec 2012
This kind of format mainly we are going to use in the PIVOT Queries as well as dynamics queries of SQL Server.
declare @date date set @date=GETDATE() print (cast(day(@date) as varchar))+' '+convert(char(3), @date, 0)+ ' '+ cast(year(@date) as varchar)
Output of the
18 Dec 2012
Post a Comment
Please give your valuable feedback on this post. You can submit any ASP.NET article here. We will post that article in this website by your name.