User tests: Successful: Unsuccessful:
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
$db = JFactory::getDbo();
$query = $db->getQuery(true);
echo $query
->select('*')
->from('#__table_1')
->unionAll(
$db->getQuery(true)
->select('*')
->from('#__table_2')
);
The code above should output "SELECT * FROM #__table_1 UNION ALL ( SELECT * FROM #__table_2)".
At the moment the output is "SELECT * FROM #__table_1".
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.
Labels |
Added:
?
|
I think I found the problem with the whitespaces. The Github editor adds tabs on each new (empty) line which I have to remove next time.
Exact
Category | ⇒ | Libraries |
Title |
|
Title |
|
I have tested this item
Still not fix for #6789.
Already fixed in #4127 PR.
Status | Pending | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2016-11-04 12:17:50 |
Closed_By | ⇒ | roland-d | |
Rel_Number | 0 | ⇒ | 10817 |
Relation Type | ⇒ | Related to |
Closed in favor of #10817
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.
I edited the file completely on Github, may this be the problem? Sorry - it's my first PR. Any help would be appreciated.