Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2024-04-03 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Aivars
 |  Kalvāns
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  1
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Sarah Boyce):

 * needs_better_patch:  0 => 1

Comment:

 Marking "Patch needs improvement" as the API is being discussed and the
 current proposal in the discussion is different to the patch
-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018ea3f8fffe-5d721311-78d0-459b-a744-c100b431cffb-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2023-10-10 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Aivars
 |  Kalvāns
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by John Speno):

 * cc: John Speno (added)


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018b1bdb9af2-9db9ffa6-3f9c-400b-bec5-677c4b784e1a-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2023-09-25 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Aivars
 |  Kalvāns
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Mariusz Felisiak):

 Please describe your proposition on the [https://groups.google.com/g
 /django-developers/c/qQ5DT91nBLM mailing list], where you'll reach a wider
 audience and see what other think.

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018acc1c1ef9-0d490807-863d-434f-952b-983d7245cfe4-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2023-09-25 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Aivars
 |  Kalvāns
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Aivars Kalvāns):

 Maybe doing {{{Foo.objects.update(x="newx", returning=True)}}} and
 returning a QuerySet would work better. I found only a single project with
 {{{returning}}} model field in github
 
https://github.com/annalee/alienplanit/blob/b54722d683a5e8eba03f4467a367bcf24339bb32/submissions/models.py#L35

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018acc14a4b5-ae58267d-916d-4bbb-9aa5-4f935e671816-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2023-09-25 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Aivars
 |  Kalvāns
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Aivars Kalvāns):

 Yes I saw it. But I did not see there a way to implement the new behavior
 without breaking the API. Is there something I missed? Returning a tuple
 with {{{(n, [data])}}} will break the code that expects a simple integer,
 making the {{{returning}}} kwarg special also can break something (but
 unlikely) and chaining of method calls like {{{.update().value()}}} is not
 possible because the update is expected to execute the SQL before
 returning.

 So asides from naming the function I think that returning models by
 default is nice because it includes PK and the result is "usable". If you
 don't need the models, you can ask for values or values_list. There are
 people using {{{QuerySet.raw()}}} to achieve similar result
 (https://hakibenita.com/django-concurrency#update-and-immediately-return)

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018acbf58fa4-f760ccfe-c7b8-45fd-b816-10e092951dfd-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2023-09-25 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  aivarsk
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Mariusz Felisiak):

 Replying to [comment:14 Aivars Kalvāns]:
 > Just because the {{{update}}} is returning the number of rows updated. I
 can do the same with {{{Foo.objects.update(x="newx", returning=True)}}}
 assuming no model will have a {{{returning}}} field. Whatever fits best, I
 just want to be able to do {{{returning}}} without executing a raw SQL.

 Have you seen the [https://groups.google.com/g/django-
 developers/c/qQ5DT91nBLM mailing list discussion]? There are some
 proposals to use the current methods without breaking backward
 compatibility, e.g. `namedtuple`.

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018acbde3be1-9e5b0044-0ca5-4acb-bd5d-445105cc220b-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2023-09-25 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Aivars
 |  Kalvāns
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Aivars Kalvāns):

 Just because the {{{update}}} is returning the number of rows updated. I
 can do the same with {{{Foo.objects.update(x="newx", returning=True)}}}
 assuming no model will have a {{{returning}}} field. Whatever fits best, I
 just want to be able to do {{{returning}}} without executing a raw SQL.

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018acbcf23ed-c690936f-5d5e-42d0-9ca4-d426abd698c3-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2023-09-25 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  aivarsk
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Mariusz Felisiak):

 We don't have, and never need a separate method for `INSERT ...
 RETURNING`), so I'm not sure why you want to handle `UPDATE ... RETURNING`
 in a separate method.

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018acbbdf20e-1f498909-1e3b-4bf8-a494-baa5d665bff2-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2023-09-25 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Aivars
 |  Kalvāns
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Aivars Kalvāns):

 * has_patch:  0 => 1


Comment:

 I created a [https://github.com/django/django/pull/17307 PR]

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018acbbce3ce-b2db53f9-1a52-4a60-8b69-da93eb8e0ab6-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2023-09-25 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  aivarsk
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by aivarsk):

 * owner:  (none) => aivarsk
 * status:  new => assigned


Comment:

 I have a proof of concept in my branch, I will clean up and open a PR this
 week. But I took a slightly different approach so I would like to get some
 feedback.

 I added a new `.update_returning` method that returns a query set instead
 of changing the existing `.update` that returns a number. That allows us
 to do things like:

 we can get the model after the update which is the main use case IMO. I
 have used this approach in accounting systems, there are some articles
 showing when it's useful https://hakibenita.com/django-concurrency#update-
 and-immediately-return
 {{{
 #!python
 updated = (
 UpdateReturningModel.objects.filter(key=obj.key)
 .update_returning(hits=F("hits") + 1)
 .get()
 )
 }}}

 we can also do some lazy loading
 {{{
 #!python
 updated = (
 UpdateReturningModel.objects.filter(key=obj.key)
 .update_returning(hits=F("hits") + 1)
 .only("hits")
 .get()
 )

 updated = (
 UpdateReturningModel.objects.filter(key=obj.key)
 .update_returning(hits=F("hits") + 1)
 .defer("hits", "content")
 .get()
 )
 }}}

 or keep working without models
 {{{
 #!python
 updated = UpdateReturningModel.objects.update_returning(
 hits=F("hits") + 1
 ).values("pk", "hits")

 updated = UpdateReturningModel.objects.update_returning(
 hits=F("hits") + 1
 ).values_list("hits", flat=True)
 }}}

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018acb5f924c-ad7a63e0-6c88-4e1b-9e57-256e79a38e84-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2022-12-30 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  (none)
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Michael Rosner):

 * cc: Michael Rosner (added)


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/01070185647b8f3f-0f212f48-c63a-4b1e-af54-13251fb02375-00%40eu-central-1.amazonses.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2022-01-17 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  (none)
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Tom Carrick):

 * owner:  Tom Carrick => (none)
 * status:  assigned => new


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.0f6e0e0a5339bde74f2c2748723224cf%40djangoproject.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2021-06-06 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Tom
 |  Carrick
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Johannes Maron):

 Hi there,

 Interesting cases. DB triggers make things slightly more difficult as the
 `db_returning` feature is currently only tested for inserts not updates.

 I would see two things here, first, to add `db_retuning` support to a
 `save` call (single object update). Second, you could build on those API
 changes to add this functionality to `update`.
 Honestly, with #470 on its way. It stands to reason, if it made sense to
 refresh and object from the database by default. But that's a mailing list
 discussion for future me ;)

 In any event, this proposal seems justified to me. If you find the time to
 tackle it, I am happy to help out with reviews.

 Best,
 Joe

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.67daa1e37a6a1691505bbb07fb9317b0%40djangoproject.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2021-06-05 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Tom
 |  Carrick
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Tom Carrick):

 Johannes, I originally saw a couple of use-cases:

 1. There is some before update trigger that changes the data. If I
 understand it, `db_returning` should cover this (I had no idea it existed
 as it's not documented).
 2.  You are creating an API (or not an API) with a bulk update feature,
 and you want to return the results to the user without making another
 query to gather them.

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.3e3b9bf1f3424f69c3423e88a3117376%40djangoproject.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2021-06-05 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Tom
 |  Carrick
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Johannes Maron):

 Hi there, I implemented the `returning` support in the past. I believe
 this feature is possible, however, I think we need to be sure how this
 differs from setting `db_returning` on the fields itself. In case you
 didn't know (it's not documented yet) You have multiple return values by
 setting that attribute to true. I would be curious if you could provide a
 more detailed use case. Best, Joe

 FYI, this might be somewhat related to #30032 and #470

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.3dc8e98e0eb57b903cae0642841e825b%40djangoproject.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2021-06-05 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Tom
 |  Carrick
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Johannes Maron):

 * cc: Johannes Maron (added)


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.9a99ad9f56b415ac295e96e0798f2e6c%40djangoproject.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2021-03-14 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Tom
 |  Carrick
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Diego Lima):

 * cc: Diego Lima (added)


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.04733eebcba66d44b31a42ee0eae67e5%40djangoproject.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2021-02-18 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Tom
 Type:   |  Carrick
  Cleanup/optimization   |   Status:  closed
Component:  Database layer   |  Version:  master
  (models, ORM)  |   Resolution:
 Severity:  Normal   |  worksforme
 Keywords:  Mango| Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  1
  Needs tests:  1|  Patch needs improvement:  1
Easy pickings:  1|UI/UX:  1
-+-
Changes (by Hery127):

 * cc: Hery127 (added)
 * needs_better_patch:  0 => 1
 * needs_tests:  0 => 1
 * easy:  0 => 1
 * keywords:   => Mango
 * needs_docs:  0 => 1
 * has_patch:  0 => 1
 * ui_ux:  0 => 1
 * type:  New feature => Cleanup/optimization


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.db250258a1e7e2d57e3ade1e074ee833%40djangoproject.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2021-02-18 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Tom
 |  Carrick
 Type:  New feature  |   Status:  closed
Component:  Database layer   |  Version:  master
  (models, ORM)  |   Resolution:
 Severity:  Normal   |  worksforme
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Hery127):

 * status:  assigned => closed
 * resolution:   => worksforme


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.9a63c2ef22768ac1112970db77edff7a%40djangoproject.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2021-02-04 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Tom
 |  Carrick
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  master
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Chris Jerdonek):

 Recently, on issue #32381 about `bulk_update()`,
 [https://code.djangoproject.com/ticket/32381#comment:1 I suggested] the
 idea of returning different values as attributes of a single result object
 (e.g. a `namedtuple`). That was about `bulk_update()` rather than
 `update()`, but the principle is the same. In this case, the two possible
 values under consideration could be approximately named something like
 `number_matched` and `values`.

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.7c2c7ebe1cacf014169aa6d9be930125%40djangoproject.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2021-02-02 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Tom
 |  Carrick
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  master
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Carlton Gibson):

 * stage:  Unreviewed => Accepted


Comment:

 OK, I'll provisionally accept on the basis of the discussion.
 It would be good if we could pin down an API that was generally agreed
 upon (ref the return value seems the main sticking point) before
 implementation began.

-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.7ec83b3f7681f5c13edd115b3fac1e03%40djangoproject.com.


Re: [Django] #32406: Allow QuerySet.update() to return fields on supported backends.

2021-02-01 Thread Django
#32406: Allow QuerySet.update() to return fields on supported backends.
-+-
 Reporter:  Tom Carrick  |Owner:  Tom
 |  Carrick
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  master
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:
 |  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Tom Carrick):

 * owner:  nobody => Tom Carrick


-- 
Ticket URL: 
Django 
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 django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.b8ec89a3b736761e46b6571c54c9c164%40djangoproject.com.