wassimqa
asked on
Datetime
Hello,
I'm new to SQL.
Here's my question,
I need to get the hour and minutes to show like hm, example (832 or 1125 or ...),
I used this :
SELECT DATEPART(hour,My Field)
SELECT DATEPART(minute,My Field)
it gives me the info, but I can't seem able to combine both.
Thanks for any help.
I'm new to SQL.
Here's my question,
I need to get the hour and minutes to show like hm, example (832 or 1125 or ...),
I used this :
SELECT DATEPART(hour,My Field)
SELECT DATEPART(minute,My Field)
it gives me the info, but I can't seem able to combine both.
Thanks for any help.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Ooops,
yes, I missed the comma,
Beginners mistake,
Thanks again.
yes, I missed the comma,
Beginners mistake,
Thanks again.
ASKER
excellent work
ASKER
SELECT cast(REPLACE(CONVERT(varch
My field looks like: May 29 2008 8:22AM