Formatting Of Timestamp
In my procedure I have formatted timestamp as follows
Var_Abc varchar2 is output of the procedure
select to_char(max(datestamp),'DD-MON-YYYY hh24:mi:ss'
into var_Abc
from Mytbl
It gives 25-apr-2011 05: 23: 45 pm
But when it is printed in Java eclipse console it's showing 23-apr-2011 11:32:3开发者_StackOverflow中文版4 (approx) We are not doing any manipulation of this output var_abc.
Can somebody explain this discrepency in data from Oracle to Java output.
I suspect your timestamp is a timestamp with time zone; note that the timestamp is changing exactly six hours. What's your local GMT offset?
精彩评论