In most of the scenarios, the date selected on the UI is of the format java.util.Date but the column store in the database will be of the format oracle.jbo.domain.Timestamp.
Convert Date to Timestamp
java.util.Date dateObj;
oracle.jbo.domain.Timestamp timestampObj = new oracle.jbo.domain.Timestamp(dateObj);
Convert Timestamp to Date
oracle.jbo.domain.Timestamp timestampObj;
java.util.Date dateObj = new java.util.Date(timestampObj.getTime());
Thanks!!
ReplyDelete