#30319: model.save() surprising behavior with update_fields specified and 
auto_now
field in model
-------------------------------------+-------------------------------------
     Reporter:  sebhaase             |                    Owner:  nobody
         Type:  Uncategorized        |                   Status:  closed
    Component:  Database layer       |                  Version:  2.1
  (models, ORM)                      |
     Severity:  Normal               |               Resolution:  wontfix
     Keywords:                       |             Triage Stage:
                                     |  Unreviewed
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------

Comment (by sebhaase):

 I would still suggest to rephrase:
 "There will be a slight performance benefit from preventing all of the
 model fields from being updated in the database."
 to
 "There will be a slight performance benefit from preventing all of the
 model fields from being updated in the database. Note that `auto_now=True`
 fields will be stay untouched unless explicitly listed in
 `update_fields`."

 I'm sure I'm not the only who got tripped by this - otherwise the docs of
 django a really superb!

-- 
Ticket URL: <https://code.djangoproject.com/ticket/30319#comment:3>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.d5157eaba0b2d3f99d28b2456a3a5d37%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to