On 13 joulu, 22:11, Emil Stenström wrote:
> I just thinking out loud here but: what if another thread does something to
> the previously loaded object? I'm not sure if Django has concurrency tests
> build into the test suite, but if it hasn't it could explain why the code
> is written as it is.
I
I just thinking out loud here but: what if another thread does something to
the previously loaded object? I'm not sure if Django has concurrency tests
build into the test suite, but if it hasn't it could explain why the code
is written as it is.
On Friday, 30 November 2012 19:53:32 UTC+1, Anssi
I would like to change the implementation of .save(). In the following
case:
s = SomeModel.objects.get(pk=somepk)
s.somefield = val
s.save()
we currently do this:
SELECT (from .get())
SELECT (from .save())
UPDATE
The second SELECT is redundant. We have knowledge that the model was
loaded from t