我有一个列出所有记录的代码。但我希望它是降序的。这是我的代码:
<%
ChangeRequestDetails changeRequestDetails = new ChangeRequestDetails();
List<ChangeRequestBean> changerequestlistchangeRequestDetails.getAllChangeRequests();
%>
<table>
<tr>
<th>Id</th>
<th>Requestor</th>
<th>Description</th>
<th>Category</th>
<th>Type</th>
<th>Priority</th>
<th>Approval</th>
</tr>
<%
for (ChangeRequestBean changerequest: changerequestlist) {
%>
<tr class="gradeB">
<td><%=changerequest.getChangerequestid()%></td>
<td><%=changerequest.getUserdivisionid()%></td>
<td><%=changerequest.getDefchangerequest()%></td>
<td><%=changerequest.getCategory()%></td>
<td><%=changerequest.getChangerequesttype()%></td>
<td><%=changerequest.getChangerequestpriority()%></td>
<!--<td><%=changerequest.getDatestamp()%></td>-->
<td><%=changerequest.getApproval()%></td>
</tr>
<%}%>
</table>
请帮忙,我希望它按降序排列的原因是因为我想查看最近添加的记录。提前谢谢你们。