You need to do from database side, either stored procedure or db script to group by the id ahead of time. It will display one row after you done that