Replies: 1 comment
-
I haven't done this myself, but I think you'd have to do something like |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Admin::update_many() .col_expr(admin::Column::Mailing, Expr::value(admin::Column::Mailing+1)) .filter(admin::Column::Id.eq(2)) .exec(&self.db) .await;
UPDATE admin SET mailing = mailing + 1 WHERE id = 2;
I want to update the number in a column. Namely, add a number. I don't want to do it through "find". I wanted to do it as in the code above, but it didn’t work. Tell me how to do it through "update_many"
Beta Was this translation helpful? Give feedback.
All reactions