-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Problem with JDatabaseQuery __toString #6693
Conversation
unionAll did not work as expected, ie the string you entered into the unionAll method was never appended to the SQL query
It does not seem to be a problem with the tests, but rather with my file. Travis keeps telling me
I can't find any whitespaces at these lines. |
@fruppel i have just send you a PR to fix the whitespaces 😄 |
fix whitespaces for #6693
Thank you @zero-24 👍 |
Exact 😄 |
Update from original
Update from original
Changed the order of "ORDER" and "UNION/UNION ALL" to fix #6789 |
Confirmed that this pull requests fixes the related issue in #6789. |
Object to applying order to the set. See #3565 |
The fix objected #3565
@sovainfo ok I understand the problem. I reverted my last commit |
I have tested this item 🔴 unsuccessfully on 8d6bb9f Already fixed in #4127 PR. This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/6693. |
Can we close it as it is fixed at #10817 |
Closed in favor of #10817 This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/6693. |
There is an issues with the __toString method of the class JDatabaseQuery.
unionAll did not work as expected, ie the string you entered into the unionAll method was never appended to the SQL query
Steps to reproduce the issue
Expected result
The code above should output "SELECT * FROM #__table_1 UNION ALL ( SELECT * FROM #__table_2)".
Actual result
At the moment the output is "SELECT * FROM #__table_1".
Additional comments
This PR also fixes a problem with the ordering of UNION and ORDER BY. You can see how to reproduce and test it here: #6789.