File tree Expand file tree Collapse file tree 1 file changed +23
-5
lines changed
Expand file tree Collapse file tree 1 file changed +23
-5
lines changed Original file line number Diff line number Diff line change @@ -632,12 +632,30 @@ def update(
632632 """
633633 Update rows.
634634
635- await Band.update().values(
636- {Band.name: "Spamalot"}
637- ).where(
638- Band.name=="Pythonistas"
639- ).run()
635+ All of the following work, though the first is preferable:
636+
637+ .. code-block:: python
638+
639+ await Band.update(
640+ {Band.name: "Spamalot"}
641+ ).where(
642+ Band.name=="Pythonistas"
643+ ).run()
644+
645+ await Band.update(
646+ {"name": "Spamalot"}
647+ ).where(
648+ Band.name=="Pythonistas"
649+ ).run()
650+
651+ await Band.update(
652+ name="Spamalot"
653+ ).where(
654+ Band.name=="Pythonistas"
655+ ).run()
656+
640657 """
658+ values = dict (values , ** kwargs )
641659 return Update (table = cls ).values (values )
642660
643661 @classmethod
You can’t perform that action at this time.
0 commit comments