- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for moving (0.17 sec)
-
tests/group_by_test.go
t.Errorf("name should be groupby, but got %v, total should be 60, but got %v", name, total) } if err := DB.Model(&User{}).Select("name, sum(age) as total").Where("name LIKE ?", "groupby%").Group("name").Having("name = ?", "groupby1").Row().Scan(&name, &total); err != nil { t.Errorf("no error should happen, but got %v", err) } if name != "groupby1" || total != 660 {
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Thu Jan 06 07:02:53 GMT 2022 - 3.3K bytes - Viewed (0) -
clause/group_by_test.go
Columns: []clause.Column{{Name: "role"}}, Having: []clause.Expression{clause.Eq{"role", "admin"}}, }}, "SELECT * FROM `users` GROUP BY `role` HAVING `role` = ?", []interface{}{"admin"}, }, { []clause.Interface{clause.Select{}, clause.From{}, clause.GroupBy{ Columns: []clause.Column{{Name: "role"}}, Having: []clause.Expression{clause.Eq{"role", "admin"}}, }, clause.GroupBy{
Go - Registered: Sun May 05 09:35:13 GMT 2024 - Last Modified: Thu Jan 06 07:02:53 GMT 2022 - 1.1K bytes - Viewed (0)