Does gorm supports distinct functionality? Such as db.Where("id = ?", id).Distinct("name").Find(&users);
I didn't find function like "Distinct"... I only can use db.Raw("SELECT DISTRINCT *** FROM) instead...
Use Select("DISTRINCT(xxx)")?
Select("DISTRINCT(xxx)")
Most helpful comment
Use
Select("DISTRINCT(xxx)")?