I am trying to retreive a string in this format dd-MM-yyyy hh:mm:ss a from Oracle database from the column of type Date which has value 10/09/2007 07:11:16
Date strfinaldate = new java.util.Date(rs.getTimestamp(10).getDate()+rs.ge tTimestamp(10).getTime());
SimpleDateFormat sf = new SimpleDateFormat ("dd-MM-yyyy hh:mm:ss a");
String formatteddate = sf.format(strfinaldate );
But I am getting the o/p as 10-09-2007 12:00:00 am
Please tell me how do I get the exact date/time
Thanks