SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
Register Now and get your question answered!
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Starting Member

4 Posts

Posted - 05/16/2013 :  09:36:05  Show Profile  Reply with Quote
I want the above format but CONVERT(DATE,MAX(CAST(VALUE AS date)),101) gives me yyyy/mm/dd what do i need to do

Flowing Fount of Yak Knowledge

8780 Posts

Posted - 05/16/2013 :  09:40:44  Show Profile  Visit webfred's Homepage  Reply with Quote
CONVERT(varchar(10),MAX(CAST(VALUE AS date)),101)

Too old to Rock'n'Roll too young to die.
Go to Top of Page

Starting Member

4 Posts

Posted - 05/16/2013 :  09:46:31  Show Profile  Reply with Quote
Go to Top of Page

Premature Yak Congratulator

22847 Posts

Posted - 05/17/2013 :  04:30:19  Show Profile  Send madhivanan a Yahoo! Message  Reply with Quote
However if you want to show them in a front end application, you can return DATETIME values as such and use format function there


Failing to plan is Planning to fail
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.06 seconds. Powered By: Snitz Forums 2000