#17117Allow empty $from_table in SELECTquery()
Description
The following query will fail:
$TYPO3_DB->exec_SELECTquery( ‘SELECT 1’, ‘’, ‘’);
because it builds a query like:
SELECT DATE_FORMAT( SUBDATE, “%d.%m.%Y” );
FROM
The above example is kind of stupid, but it can make sense to use queries without a table, e.g. when using MySQL for date handling.
The attached patch will handle an empty $from_table correctly, by omitting the “FROM”.
(issue imported from #M5215)
Reviews 0
No change resolves or names this issue in its commit message, and no comment links one.