Delete duplicate information at the db level

@alex1368 if you have more complicated scenarios you can use the WINDOW function in SQL (depending on your database) to have more control about what duplicate you want to remove.