Hi Peter, Thanks for asking!
On Sunday 28 September 2014 02:01:59 Peter Geoghegan wrote: > > * Would you consider the syntax that I've proposed a good one? > Looks pretty reasonable. > * If it was available, would you use it in future versions of Django? > Do you think the plugins ecosystem could take advantage of it sooner? > Is the demand there? > I agree with Alex here. Probably will get used in Django. However, Django tries to be compatible with all currently supported versions of PG; so I will be a little surprised if it gets used before PG 9.4's EOL. Plugins (or, as we call them, apps) in the ecosystem will be at liberty to use it much sooner, of course, but for them there are strong incentives to stay with the cross-database API. The next release, Django 1.8, will probably include a library to support PG-only development, so such incentives will be a little weaker there. > * What could be better about the feature? > Upon reading the docs, I was a little surprised to see that in terms of triggers etc, the operation is always considered an INSERT. I would expect it to be considered an insert for BEFORE INSERT or INSTEAD OF INSERT triggers, but if conflict resolution turns it into an UPDATE, I'd expect to see it handled as an UPDATE from that point on (definitely INSTEAD OF UPDATE and AFTER UPDATE triggers, maybe even BEFORE UPDATE). That is the semantics we have now (this is a general remark, not particulary Django-oriented; Django does not use triggers on PG as far as I know, and only uses them elsewhere to implement serial keys). Could you explain the reasoning behind the described behavior? Thanks, Shai. -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-developers+unsubscr...@googlegroups.com. To post to this group, send email to django-developers@googlegroups.com. Visit this group at http://groups.google.com/group/django-developers. To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/201409280422.30231.shai%40platonix.com. For more options, visit https://groups.google.com/d/optout.