What is the difference between write and update method in odoo11 because when i use write it work first time only then it not work.
For simple fields
write({'attr1': 'val1', 'attr2': 'val2'})
should give you a single update statement in the database, and
update({'attr1': 'val1', 'attr2': 'val2'})
iterates over the fields and sets each one separately giving you multiple update statements in the database.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With