-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fixed #5622 - mysql 5.7 ONLY_FULL_GROUP_BY #6143
Conversation
I just tested this in our project and it seems to solve the issues. Really awesome! 👍 Would be great if this could get merged. |
Confirmed here too, +1 for a merge :) |
Looks good. Let's merge this! |
@Ocramius thank you. |
Simply didn't get to it, sorry.
Marco Pivetta
http://twitter.com/Ocramius
http://ocramius.github.com/
…On Wed, Mar 15, 2017 at 1:18 PM, chihiro-adachi ***@***.***> wrote:
@Ocramius <https://github.com/Ocramius>
this pr Is there something wrong?
anything else needed?
thank you.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#6143 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAJakJiQrYhcTpaQqIV6L6P8Xxi9ZjFcks5rl9cBgaJpZM4K5JxB>
.
|
lgtm 👍 |
is this on deck to be pulled in anytime soon? |
+1 |
1 similar comment
+1 |
copy fixed doctrine#5622 - mysql 5.7 ONLY_FULL_GROUP_BY doctrine#6143 chihiro-adachi wants to merge 2 commits into doctrine:master from chihiro-adachi:patch-1
copy fixed doctrine#5622 - mysql 5.7 ONLY_FULL_GROUP_BY doctrine#6143 chihiro-adachi wants to merge 2 commits into doctrine:master from chihiro-adachi:patch-1
+1 |
@Ocramius I've synced this PR with |
Any SQL-compliant platform should require this fix. |
why still not merge? |
@Arkemlar because I'd rather not have support for MySQL 5.7 than having security issues due to regex-based SQL manipulation. The patch may be good, but it will need further checking for edge-cases in the newly added conditionals. Also, tests were only modified so far, but none was added. |
Should fix MySQL 5.7 issues caused by ONLY_FULL_GROUP_BY
Following the same setup of doctrine/dbal#2764.
Also simplifying the REGEX to remove the ORDER BY type (ASC/DESC) with a substr() since OrderByItem#type is always defined.
Looking good according to @lcobucci's changes: will likely merge today. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍 🚢
Will this be merged into stable versions as a bugfix? |
@chihiro-adachi this is already in |
Is |
No, mysql 5.7 is just officially supported in 2.6 (unstable version).
…On Mon, 24 Jul 2017, 12:18 Teoh Han Hui, ***@***.***> wrote:
Is 2.6.0 released yet? I can't find it anywhere. But I mean this should
be treated as a bug, right? If so, might it be fixed in the currently
supported versions?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#6143 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAMU6w196JWvvHIDEAOkedRI0LTy9zlZks5sRG-NgaJpZM4K5JxB>
.
|
@teohhanhui no, newer mysql versions broke BC and we simply support them in a newer version only. |
I thought this bug is also present when using other SQL-compliant platforms such as PostgreSQL... Because this bug only manifested itself when MySQL started becoming more SQL-compliant. |
@teohhanhui yes, but only MySQL crashes hard. So far, the only issue with such queries was non-deterministic result due to ordering. |
@teohhanhui If you can't wait for Doctrine 2.6 to be released you still have the hackish way of overriding the Autoloader in your composer.json:
Just put the fixed source from this PR into the But keep in mind that this is pretty hackish. On the other hand if a project is blocked because of this you sometimes just don't have a choice. |
Is this not backported to 2.5 ? Since my company uses Ubuntu 16.04 LTS and the 2.6 branch does not support PHP 7.0 I cannot upgrade to 2.6. @ureimers solution works but I would prefer a cleaner solution if possible. I tried using the patch generated by this pull request but it is not compatible with 2.5. Now trying to strip down this patch so the changes can be applied to 2.5 but was wondering why this bugfix is 2.6 only. |
@InfopactMLoos no, you will need to upgrade to
MySQL 5.7 support is an addition. |
Yeah I know how to do that through ppa it's easy indeed but company policy is to keep everything LTS compatible. We try to minimize customizations to base server images. Ok no worries I just completed rolling the patch and it seems to work fine. Was just wondering why, anyway thanks for the quick response! |
It seems like there should be a version of Doctrine that supports both PHP 7.0 and MySQL given that those are the available versions in Ubuntu 16.04 |
Won't happen, as that is just pushing back the ecosystem with the excuse that the ecosystem is already being pushed back. You can simply rely on the PPAs by ondrej, which reflect PHP core development, on which you can rely for security maintenance as well. |
#5622
I fixed it with reference to #5973
please check.