Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2017-09-22 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  closed
Component:  Database layer   |  Version:  master
  (models, ORM)  |
 Severity:  Normal   |   Resolution:  fixed
 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 Tim Graham ):

 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"01d440fa1e6b5c62acfa8b3fde43dfa1505f93c6" 01d440fa]:
 {{{
 #!CommitTicketReference repository=""
 revision="01d440fa1e6b5c62acfa8b3fde43dfa1505f93c6"
 Fixed #27332 -- Added FilteredRelation API for conditional join (ON
 clause) support.

 Thanks Anssi Kääriäinen for contributing 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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.545124003ff766714f8c178029b4f4e6%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2017-09-08 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:  master
  (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 Tim Graham):

 * needs_better_patch:  1 => 0
 * version:   => master


-- 
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.db8b8a8f15d9f93986e0c73e3cd0e4e6%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2017-02-15 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Josh Smeaton):

 * cc: josh.smeaton@… (added)


Comment:

 Sorry, I wasn't aware this patch existed, or I would have tried to review
 for 1.11. I'll make some time to review this patch in the next few weeks.

--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.d73a80b94b59b83536b2c97610a54f5e%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2017-01-09 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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
-+-

Comment (by Daniel Hahler):

 PR review comments have been addressed.
 Please consider including it for Django 1.11.

--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.171238be0aa6c1b5c4df5845bc65dfa3%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-12-29 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Tim Graham):

 * needs_better_patch:  0 => 1


--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.acea0d13146b0c764b78dc0e8e4174d8%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-11-15 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Claude Paroz):

 * has_patch:  0 => 1


--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.9d53a792a162be8d96fe64dccdc98a30%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-11-15 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Nicolas Delaby):

 * cc: ticosax@… (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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.5a7c61e7ab0b0c30342d14581395c3d2%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-11-15 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Nicolas Delaby):

 https://github.com/django/django/pull/7560

--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.f73833c71bc0990227ac7908b341afc9%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-11-14 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Daniel Hahler):

 * cc: django@… (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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.839bf9f9d19c98a4b230f3fa55524f29%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-11-14 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Nicolas Delaby):

 Thanks Anssi for your feedback. I'll start from your proposal.

--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.03304c2b0e687b86cc6f458d2ca515f2%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-11-11 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Simon Charette):

 * cc: Simon Charette (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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.0bc25cf9fd80039d2a6cf340423e20ec%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-11-11 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Anssi Kääriäinen):

 This is something I've wanted for a long time.

 Some considerations:
   - In general the ORM API tries to avoid SQL specific terms like join.
 Maybe relation would be a better term to use?
   - The API shouldn't edit the current relation, instead it should add a
 new lookup path alias. So: .filtered_relation('translations',
 alias='translation_fi',
 condition=Q(translations__lang='fi')).filter(translation_fi__title=...)

--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.48f927c84e4ef810bb5a77b511650f4d%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-11-11 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 MikiSoft):

 Awesome! Looking forward to its implementation in Django. :)

--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.cee5f1ed2814c2156ee5c71ea0d55cae%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-11-11 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Nicolas Delaby):

 Hi,
 I started to look at this one and realized {{{GenericForeignKey}}}
 implemented such functionnality in {{{ get_extra_restriction() }}}

 
https://github.com/django/django/blob/master/django/contrib/contenttypes/fields.py#L437

 So I followed that path, and came up with a PoC implementation (with
 passing tests), following this API:

 {{{#!python
 class ConditionalJoinTests(TestCase):

 @classmethod
 def setUpTestData(cls):
 cls.author1 = Author.objects.create(name='Alice')
 cls.author2 = Author.objects.create(name='Jane')

 cls.book1 = Book.objects.create(title='Poem by Alice',
 editor='A',
 author=cls.author1)

 cls.book2 = Book.objects.create(title='The book by Jane A',
 editor='A',
 author=cls.author2)

 cls.book2 = Book.objects.create(title='The book by Jane B',
 editor='B',
 author=cls.author2)

 def test_conditional_join_query_wo_join(self):
 """
 All Authors are returned because no join is required by the
 filters.
 """
 self.assertQuerysetEqual(
 Author.objects
 .conditional_join('book', title__iexact='poem by alice'),
 ["", ""])

 def test_conditional_join_query_with_join(self):
 self.assertQuerysetEqual(
 Author.objects
 .conditional_join('book', title__iexact='poem by alice')
 .filter(book__isnull=False),
 [""])

 self.assertQuerysetEqual(
 Author.objects
 .conditional_join('book', Q(title__iexact='poem by alice'))
 .filter(book__isnull=False),
 [""])

 def test_conditional_join_query_with_join_multiple(self):
 self.assertQuerysetEqual(
 Author.objects
 .conditional_join('book', title__icontains='jane', editor='B')
 .filter(book__isnull=False),
 [""])
 }}}

 If this proposal receives some interest, I'll be glad to work on preparing
 a pull request to support this use case.

--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.895d1de93e260fd575766d6eae9188f4%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins

2016-10-12 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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 Tim Graham):

 * stage:  Unreviewed => Accepted


Comment:

 I don't know. I'll tentatively accept the ticket but it might not be
 feasible to construct every query through the ORM.

--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.506b66e23a261dc985e09ce683872adb%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.


Re: [Django] #27332: Specifying additional ON arguments, and more flexibility with joins (was: Specifying additional JOIN arguments)

2016-10-10 Thread Django
#27332: Specifying additional ON arguments, and more flexibility with joins
-+-
 Reporter:  MikiSoft |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:
  (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
-+-

--
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 post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.aff2c2477f5843e4a0682b87b3d30259%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.