Skip to content

Commit

Permalink
Merge pull request go-gorm#652 from neverth/patch-1
Browse files Browse the repository at this point in the history
docs: fix error in comment
  • Loading branch information
tr1v3r authored Sep 21, 2022
2 parents e96060b + db23c29 commit d1e5812
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.ZH_CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -1650,7 +1650,7 @@ u.WithContext(ctx).Where(u.ID.Eq(111)).Updates(map[string]interface{}{"name": "h

// Update attributes with `struct`
u.WithContext(ctx).Where(u.ID.Eq(111)).Updates(model.User{Name: "hello", Age: 18, Active: false})
// UPDATE users SET name='hello', age=18, active=false, updated_at='2013-11-17 21:34:10' WHERE id=111;
// UPDATE users SET name='hello', age=18, updated_at='2013-11-17 21:34:10' WHERE id=111;

// Update with expression
u.WithContext(ctx).Where(u.ID.Eq(111)).UpdateSimple(u.Age.Add(1), u.Number.Add(1))
Expand Down

0 comments on commit d1e5812

Please sign in to comment.