On Sep 22, 9:48 am, Szymon <szy...@mwg.pl> wrote:
> On 21 Wrz, 22:47, Javier Guerra <jav...@guerrag.com> wrote:
>
> > only if you include it in the parameter list:
>
> Oh, yes. I forget about self in my example, but in function that makes
> problem there is of course self in parameter list.

I suspect the problem isn't quite what you think it is. It looks like
the new value of the object will always be saved to the database, and
that instance will carry the new value. However, Django model
instances are independent of the database and of other instances that
refer to the same database row. So, if you have another instance
somewhere else in your code with the same database id, it won't be
updated even if you save this one - you'll need to get it again from
the database,
--
DR.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to