I have a Map
containing the birthdate of a person as a GregorianCalendar
.
For example:
{
motherEmailID=null,
coreType=Ticket,
_NULL=null,
additionalFaclitiesProvided=[],
dateOfBirth=java.util.GregorianCalendar[
time=585340200000,
areFieldsSet=false,
areAllFieldsSet=false,
lenient=true,
zone=sun.util.calendar.ZoneInfo[id="GMT",
offset=0,
dstSavings=0,
useDaylight=false,
transitions=0,
lastRule=null],
firstDayOfWeek=1,
minimalDaysInFirstWeek=1,
ERA=1,
YEAR=1988,
MONTH=6,
WEEK_OF_YEAR=30,
WEEK_OF_MONTH=4,
DAY_OF_MONTH=20,
DAY_OF_YEAR=202,
DAY_OF_WEEK=4,
DAY_OF_WEEK_IN_MONTH=3,
AM_PM=0,
HOUR=0,
HOUR_OF_DAY=0,
MINUTE=0,
SECOND=0,
MILLISECOND=0,
ZONE_OFFSET=19800000,
DST_OFFSET=0],
targetEnd=null,
year_semester=null
}
I need a Date
, but in my database it is in Calendar
format only.
The datatype of column in the database is DateTime
.
How can I get the birthdate in a Date
format?