Update a model in database - To apply where conditions / filters, see [`QueryFilter`](crate::query::QueryFilter) # Example (Postgres) ``` # use sea_orm::{error::*, tests_cfg::*, *}; # # #[smol_potat::main] # #[cfg(feature = "mock")] # pub async fn main() -> Result<(), DbErr> { # # let db = MockDatabase::new(DbBackend::Postgres) # .append_query_results([ # [fruit::Model { #
(model: A)
| 737 | /// # } |
| 738 | /// ``` |
| 739 | fn update<A>(model: A) -> UpdateOne<A> |
| 740 | where |
| 741 | A: ActiveModelTrait<Entity = Self>, |
| 742 | { |
| 743 | Update::one(model) |
| 744 | } |
| 745 | |
| 746 | /// Update many models in database |
| 747 | /// |
no outgoing calls