Seems to me a documentation example or improvement could be helpful.
On Mon, Dec 31, 2018 at 11:30 AM Joshua Cannon
wrote:
> Personally, the snippet suggested in the ticket is sufficient for my needs
> (although I'm saddened by having to duplicate the setattr logic).
> However, I filed the ticke
Personally, the snippet suggested in the ticket is sufficient for my needs
(although I'm saddened by having to duplicate the setattr logic).
However, I filed the ticket after Googling "Django conditional
update_or_create" and finding no appropriate solution. You might be right
about the use case
I think the use case is probably quite niche, and I'd like to know some
more concrete details than the current comment on the ticket "(E.g. only
update if the value of a DateTimeField is less than some value)". It may be
there's a way to achieve the same application-level outcome using a
different
Thanks for taking the time to post here Joshua!
The main reason why I asked to gather feedback from this list is that I'm
not convinced
that the benefits outweighs the additional complexity this will add to the
already quite
loaded update_or_create() signature handling and how the fact a callabl