If this is your first visit, be sure to check out the FAQ by clicking the link above.
You may have to register before you can post: click the register link above to proceed.
To start viewing messages, select the forum that you want to visit from the selection below.
Hi all,
I have two columns OPEN_DATE (ex...2007-03-27) and OPEN_TIME (ex...15:20:54)
The time format I am required to display - mm/dd/yyyy hh:mm
I am using the below script
select ltrim(rtrim(char(month(open_date))))|| '/' ||ltrim(rtrim(char(day(open_date))))||'/'||ltrim(rtrim(char(year(open_date))))||' '||ltrim(rtrim(char(hour(open_time))))||':'||ltrim (rtrim(char(minute(open_time)))) from <table>
Result : 3/27/2007 15:20
The problem is how do I get the month as '03' instead of just '3'