Click here to Skip to main content
15,892,298 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
How can I split time Forenoon or Afternoon in SQL 2005 or Oracle database.
Posted
Updated 23-Aug-10 8:03am
v2
Comments
R. Giskard Reventlov 23-Aug-10 9:02am    
Not enough information: be more specific: do you mean the actual times or the words?

1 solution

this query will return AM or PM :

SQL
Select Right(Convert(nvarchar, GETDATE(), 100), 2)


use it as you want.

------------------

Regards

H.Maadani
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900