[BUGFIX] Run scheduler from cli fails on DBAL 05/28805/3
authorAndreas Fernandez <a.fernandez@scripting-base.de>
Wed, 26 Mar 2014 07:44:07 +0000 (08:44 +0100)
committerJigal van Hemert <jigal.van.hemert@typo3.org>
Wed, 26 Mar 2014 08:00:34 +0000 (09:00 +0100)
With activated DBAL, dispatching the scheduler from cli
currently fails. The SqlParser can't handle brackets
in an ON-clause, so remove them in the query.

Resolves: #57246
Releases: 6.2
Change-Id: I2efa92392d22c854dae925da9a2396ef08bae198
Reviewed-on: https://review.typo3.org/28805
Reviewed-by: Jigal van Hemert
Tested-by: Jigal van Hemert
typo3/sysext/scheduler/Classes/Scheduler.php

index 5690f5e..7ccc0ad 100644 (file)
@@ -263,7 +263,7 @@ class Scheduler implements \TYPO3\CMS\Core\SingletonInterface {
                if (empty($uid)) {
                        $queryArray = array(
                                'SELECT' => 'tx_scheduler_task.uid AS uid, serialized_task_object',
-                               'FROM' => 'tx_scheduler_task LEFT JOIN tx_scheduler_task_group ON (tx_scheduler_task.task_group = tx_scheduler_task_group.uid)',
+                               'FROM' => 'tx_scheduler_task LEFT JOIN tx_scheduler_task_group ON tx_scheduler_task.task_group = tx_scheduler_task_group.uid',
                                'WHERE' => 'disable = 0 AND nextexecution != 0 AND nextexecution <= ' . $GLOBALS['EXEC_TIME'] . ' AND (tx_scheduler_task_group.hidden = 0 OR tx_scheduler_task_group.hidden IS NULL)',
                                'LIMIT' => 1
                        );