{"action":"created","issue":{"url":"https://api.github.com/repos/pentaho/mondrian/issues/669","repository_url":"https://api.github.com/repos/pentaho/mondrian","labels_url":"https://api.github.com/repos/pentaho/mondrian/issues/669/labels{/name}","comments_url":"https://api.github.com/repos/pentaho/mondrian/issues/669/comments","events_url":"https://api.github.com/repos/pentaho/mondrian/issues/669/events","html_url":"https://github.com/pentaho/mondrian/pull/669","id":138179031,"number":669,"title":"[MONDRIAN-2451] Mondrian generates ORDER BY sql that is invalid with default settings of MySQL 5.7.5+","user":{"login":"mr9d","id":5636693,"avatar_url":"https://avatars.githubusercontent.com/u/5636693?v=3","gravatar_id":"","url":"https://api.github.com/users/mr9d","html_url":"https://github.com/mr9d","followers_url":"https://api.github.com/users/mr9d/followers","following_url":"https://api.github.com/users/mr9d/following{/other_user}","gists_url":"https://api.github.com/users/mr9d/gists{/gist_id}","starred_url":"https://api.github.com/users/mr9d/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mr9d/subscriptions","organizations_url":"https://api.github.com/users/mr9d/orgs","repos_url":"https://api.github.com/users/mr9d/repos","events_url":"https://api.github.com/users/mr9d/events{/privacy}","received_events_url":"https://api.github.com/users/mr9d/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"mkambol","id":2934125,"avatar_url":"https://avatars.githubusercontent.com/u/2934125?v=3","gravatar_id":"","url":"https://api.github.com/users/mkambol","html_url":"https://github.com/mkambol","followers_url":"https://api.github.com/users/mkambol/followers","following_url":"https://api.github.com/users/mkambol/following{/other_user}","gists_url":"https://api.github.com/users/mkambol/gists{/gist_id}","starred_url":"https://api.github.com/users/mkambol/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mkambol/subscriptions","organizations_url":"https://api.github.com/users/mkambol/orgs","repos_url":"https://api.github.com/users/mkambol/repos","events_url":"https://api.github.com/users/mkambol/events{/privacy}","received_events_url":"https://api.github.com/users/mkambol/received_events","type":"User","site_admin":false},"assignees":[{"login":"mkambol","id":2934125,"avatar_url":"https://avatars.githubusercontent.com/u/2934125?v=3","gravatar_id":"","url":"https://api.github.com/users/mkambol","html_url":"https://github.com/mkambol","followers_url":"https://api.github.com/users/mkambol/followers","following_url":"https://api.github.com/users/mkambol/following{/other_user}","gists_url":"https://api.github.com/users/mkambol/gists{/gist_id}","starred_url":"https://api.github.com/users/mkambol/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mkambol/subscriptions","organizations_url":"https://api.github.com/users/mkambol/orgs","repos_url":"https://api.github.com/users/mkambol/repos","events_url":"https://api.github.com/users/mkambol/events{/privacy}","received_events_url":"https://api.github.com/users/mkambol/received_events","type":"User","site_admin":false}],"milestone":null,"comments":11,"created_at":"2016-03-03T13:34:50Z","updated_at":"2016-06-28T07:28:59Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/pentaho/mondrian/pulls/669","html_url":"https://github.com/pentaho/mondrian/pull/669","diff_url":"https://github.com/pentaho/mondrian/pull/669.diff","patch_url":"https://github.com/pentaho/mondrian/pull/669.patch"},"body":"This is the second attempt to resolve MONDRIAN-2451. Previous pull request was rejected: https://github.com/pentaho/mondrian/pull/661\r\n\r\nAccordint to Matt Campbell's suggestion, I've added requiresOrderByAlias()=true for the MySQL dialect. This caused a side effect with \"ORDER BY ISNULL(1) ASC, 1 ASC, ISNULL(2) ASC, 2 ASC, etc\" statements in SqlTupleReader.java so it was needed to change them to \"ORDER BY ISNULL('c0') ASC, 'c0' ASC, ISNULL('c1') ASC, 'c1' ASC, etc\".\r\n\r\nStill not sure about this change, because of Luc Boudreau's comment in source code:\r\n\r\n> Sort the union of the cubes.\r\n> The order by columns need to be numbers,\r\n> not column name strings or expressions.\r\n\r\n(SqlTupleReader.java:838)\r\n\r\nAnyway, all tests are successful now, so it might be the an answer to MONDRIAN-2451."},"comment":{"url":"https://api.github.com/repos/pentaho/mondrian/issues/comments/228972839","html_url":"https://github.com/pentaho/mondrian/pull/669#issuecomment-228972839","issue_url":"https://api.github.com/repos/pentaho/mondrian/issues/669","id":228972839,"user":{"login":"mr9d","id":5636693,"avatar_url":"https://avatars.githubusercontent.com/u/5636693?v=3","gravatar_id":"","url":"https://api.github.com/users/mr9d","html_url":"https://github.com/mr9d","followers_url":"https://api.github.com/users/mr9d/followers","following_url":"https://api.github.com/users/mr9d/following{/other_user}","gists_url":"https://api.github.com/users/mr9d/gists{/gist_id}","starred_url":"https://api.github.com/users/mr9d/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mr9d/subscriptions","organizations_url":"https://api.github.com/users/mr9d/orgs","repos_url":"https://api.github.com/users/mr9d/repos","events_url":"https://api.github.com/users/mr9d/events{/privacy}","received_events_url":"https://api.github.com/users/mr9d/received_events","type":"User","site_admin":false},"created_at":"2016-06-28T07:28:59Z","updated_at":"2016-06-28T07:28:59Z","body":"@mkambol please review."}}
{"actor":{"display_login":"mr9d"}}