#31445: Chain of unions leads to incorrect SQL query on MariaDB < 10.4 and
MySQL.
-------------------------------------+-------------------------------------
Reporter: Thodoris | Owner: felixxm
Sotiropoulos |
Type: Bug | Status: assigned
Component: Database layer | Version: 3.0
(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 felixxm):
* owner: nobody => felixxm
* status: new => assigned
* stage: Unreviewed => Accepted
Comment:
Thanks. I'm pretty confident that it's the same issue that I encounter in
#29338 (see
[https://github.com/django/django/pull/11692#issuecomment-581568690
comment]) related with using of parentheses. Unfortunately result depends
on version of MySQL/MariaDB:
- MySQL 8.0.4 and MariaDB 10.3 raise `1064, "You have an error in your SQL
syntax; check the manual that corresponds to your MySQL server version for
the right syntax to use near...`,
- MySQL 8.0.19 raises `1235, "This version of MySQL doesn't yet support
'nesting of unions at the right-hand side'"`,
- MariaDB 10.4 - works.
I will try to finally fix this.
--
Ticket URL: <https://code.djangoproject.com/ticket/31445#comment:4>
Django <https://code.djangoproject.com/>
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 [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/066.6afef0ec21d2352aad56542d4487af84%40djangoproject.com.