def update(self):
ret = True<EOL>fields = self.depopulate(True)<EOL>q = self.query<EOL>q.set_fields(fields)<EOL>pk = self.pk<EOL>if pk:<EOL><INDENT>q.is_field(self.schema.pk.name, pk)<EOL><DEDENT>else:<EOL><INDENT>raise ValueError("<STR_LIT>")<EOL><DEDENT>if q.update():<EOL><INDENT>fields = q.fields<EOL>self._populate(fields)<EOL><DEDENT>else:<EOL><INDENT>ret = False<EOL><DEDENT>return ret<EOL>
re-persist the updated field values of this orm that has a primary key