Quantcast

No support for UNION (OUTER JOIN instead)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

No support for UNION (OUTER JOIN instead)

guettli.google

We have performance issues on postgres because some SQL statements have up to six LEFT OUTER joins.


Union and intersection would be easier to read for me (human being) and maybe better to optimize for the postgres query planer.

It seems that other people have this issue, too: https://code.djangoproject.com/ticket/27260

The above ticket was closed with a comment to ask for help on the support channels. That's why I wrote here.

Have other developers seen performance issues because the SQL had a lot of LEFT OUTER joins?

Is there a work-around?

Regards,
  Thomas Güttelr

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/c9240453-b445-45c6-903d-7e057f264251%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No support for UNION (OUTER JOIN instead)

Tim Graham-2
Support for QuerySet.union(), intersection(), and difference() is added in Django 1.11.

https://github.com/django/django/commit/84c1826ded17b2d74f66717fb745fc36e37949fd

On Monday, March 13, 2017 at 11:54:15 AM UTC-4, guettli wrote:

We have performance issues on postgres because some SQL statements have up to six LEFT OUTER joins.


Union and intersection would be easier to read for me (human being) and maybe better to optimize for the postgres query planer.

It seems that other people have this issue, too: <a href="https://code.djangoproject.com/ticket/27260" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fcode.djangoproject.com%2Fticket%2F27260\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHQ7N0d-uAQ2-QySO9XfeUringsSw&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fcode.djangoproject.com%2Fticket%2F27260\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHQ7N0d-uAQ2-QySO9XfeUringsSw&#39;;return true;">https://code.djangoproject.com/ticket/27260

The above ticket was closed with a comment to ask for help on the support channels. That's why I wrote here.

Have other developers seen performance issues because the SQL had a lot of LEFT OUTER joins?

Is there a work-around?

Regards,
  Thomas Güttelr

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/b3eace2e-687b-42de-85a5-af987895330c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No support for UNION (OUTER JOIN instead)

guettli.google
Great, you and the django dev team are fast than light. Every time I spot a basic missing part, you have already solved it in the next release.

Am Montag, 13. März 2017 17:00:17 UTC+1 schrieb Tim Graham:
Support for QuerySet.union(), intersection(), and difference() is added in Django 1.11.

<a href="https://github.com/django/django/commit/84c1826ded17b2d74f66717fb745fc36e37949fd" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fdjango%2Fdjango%2Fcommit%2F84c1826ded17b2d74f66717fb745fc36e37949fd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHrYZhTfcx71AVnlnoWDtK9794Mqg&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fdjango%2Fdjango%2Fcommit%2F84c1826ded17b2d74f66717fb745fc36e37949fd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHrYZhTfcx71AVnlnoWDtK9794Mqg&#39;;return true;">https://github.com/django/django/commit/84c1826ded17b2d74f66717fb745fc36e37949fd

On Monday, March 13, 2017 at 11:54:15 AM UTC-4, guettli wrote:

We have performance issues on postgres because some SQL statements have up to six LEFT OUTER joins.


Union and intersection would be easier to read for me (human being) and maybe better to optimize for the postgres query planer.

It seems that other people have this issue, too: <a href="https://code.djangoproject.com/ticket/27260" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fcode.djangoproject.com%2Fticket%2F27260\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHQ7N0d-uAQ2-QySO9XfeUringsSw&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fcode.djangoproject.com%2Fticket%2F27260\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHQ7N0d-uAQ2-QySO9XfeUringsSw&#39;;return true;">https://code.djangoproject.com/ticket/27260

The above ticket was closed with a comment to ask for help on the support channels. That's why I wrote here.

Have other developers seen performance issues because the SQL had a lot of LEFT OUTER joins?

Is there a work-around?

Regards,
  Thomas Güttelr

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/e07b2a5b-7829-4689-a95f-18bbb30ef16f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No support for UNION (OUTER JOIN instead)

guettli.google

Just for the records, I added your work-around (until Django 1.11) to as comment on the issue tracker.

Am Dienstag, 14. März 2017 10:37:07 UTC+1 schrieb guettli:
Great, you and the django dev team are fast than light. Every time I spot a basic missing part, you have already solved it in the next release.

Am Montag, 13. März 2017 17:00:17 UTC+1 schrieb Tim Graham:
Support for QuerySet.union(), intersection(), and difference() is added in Django 1.11.

<a href="https://github.com/django/django/commit/84c1826ded17b2d74f66717fb745fc36e37949fd" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fdjango%2Fdjango%2Fcommit%2F84c1826ded17b2d74f66717fb745fc36e37949fd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHrYZhTfcx71AVnlnoWDtK9794Mqg&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fdjango%2Fdjango%2Fcommit%2F84c1826ded17b2d74f66717fb745fc36e37949fd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHrYZhTfcx71AVnlnoWDtK9794Mqg&#39;;return true;">https://github.com/django/django/commit/84c1826ded17b2d74f66717fb745fc36e37949fd

On Monday, March 13, 2017 at 11:54:15 AM UTC-4, guettli wrote:

We have performance issues on postgres because some SQL statements have up to six LEFT OUTER joins.


Union and intersection would be easier to read for me (human being) and maybe better to optimize for the postgres query planer.

It seems that other people have this issue, too: <a href="https://code.djangoproject.com/ticket/27260" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fcode.djangoproject.com%2Fticket%2F27260\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHQ7N0d-uAQ2-QySO9XfeUringsSw&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fcode.djangoproject.com%2Fticket%2F27260\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHQ7N0d-uAQ2-QySO9XfeUringsSw&#39;;return true;">https://code.djangoproject.com/ticket/27260

The above ticket was closed with a comment to ask for help on the support channels. That's why I wrote here.

Have other developers seen performance issues because the SQL had a lot of LEFT OUTER joins?

Is there a work-around?

Regards,
  Thomas Güttelr

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/a9f5c9d6-013d-426b-b62c-55e3fac10d5f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: No support for UNION (OUTER JOIN instead)

guettli.google
Just for the records. If you think further, then deprecating is_superuser, is_staff and is_active could be a solution. See: https://groups.google.com/forum/#!topic/django-developers/J9yttc7WmJU

Am Mittwoch, 15. März 2017 10:44:22 UTC+1 schrieb guettli:

Just for the records, I added your work-around (until Django 1.11) to as comment on the issue tracker.

Am Dienstag, 14. März 2017 10:37:07 UTC+1 schrieb guettli:
Great, you and the django dev team are fast than light. Every time I spot a basic missing part, you have already solved it in the next release.

Am Montag, 13. März 2017 17:00:17 UTC+1 schrieb Tim Graham:
Support for QuerySet.union(), intersection(), and difference() is added in Django 1.11.

<a href="https://github.com/django/django/commit/84c1826ded17b2d74f66717fb745fc36e37949fd" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fdjango%2Fdjango%2Fcommit%2F84c1826ded17b2d74f66717fb745fc36e37949fd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHrYZhTfcx71AVnlnoWDtK9794Mqg&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fgithub.com%2Fdjango%2Fdjango%2Fcommit%2F84c1826ded17b2d74f66717fb745fc36e37949fd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHrYZhTfcx71AVnlnoWDtK9794Mqg&#39;;return true;">https://github.com/django/django/commit/84c1826ded17b2d74f66717fb745fc36e37949fd

On Monday, March 13, 2017 at 11:54:15 AM UTC-4, guettli wrote:

We have performance issues on postgres because some SQL statements have up to six LEFT OUTER joins.


Union and intersection would be easier to read for me (human being) and maybe better to optimize for the postgres query planer.

It seems that other people have this issue, too: <a href="https://code.djangoproject.com/ticket/27260" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fcode.djangoproject.com%2Fticket%2F27260\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHQ7N0d-uAQ2-QySO9XfeUringsSw&#39;;return true;" onclick="this.href=&#39;https://www.google.com/url?q\x3dhttps%3A%2F%2Fcode.djangoproject.com%2Fticket%2F27260\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHQ7N0d-uAQ2-QySO9XfeUringsSw&#39;;return true;">https://code.djangoproject.com/ticket/27260

The above ticket was closed with a comment to ask for help on the support channels. That's why I wrote here.

Have other developers seen performance issues because the SQL had a lot of LEFT OUTER joins?

Is there a work-around?

Regards,
  Thomas Güttelr

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/153623e2-ddd9-4a67-abff-fed79d405d4c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...