Using Case to convert Date format in SQL Select
Explanation and demonstration of some Oracle SQL functions to convert text to dates.
Use a SQL script to generate well formatted stored procedures in SQL Server
IntroductionWhen and how to use sql formatting functions to format datetime values when it is being used by the application that is target to be run
select aday, code, convert(varchar(5), min(atime), (108))MinTime, convert(varchar(5), max(atime),(108)) MaxTime from testgroup by aday,codeorder by aday asc