I'm making a website where customers can make reservations. Here I am going to save the reservation date to database. The date is saved in the database in "YYYY-MM-DD" format. (eg -: 2020-05-12)
The code in creating the column is startDate DATE
In my jsp page, I'm going to retrieve the reservation details as a list.
The code is as follows.
<core:forEach items="${pendingReservations}" var="reservation">
<tr>
<td>${reservation.startDate}</td>
</tr>
This code works perfectly fine except it shows the date in "YYYY-MM-DD HH:MM:SS" format. (eg -: 2020-05-12 00:00:00.0)
Here, I want to dispay the date in YYYY-MM-DD format. How can I do this?