SELECTquery()¶
What does it do?¶
The method sends a SQL-Select statement and returns a SQL query.
Header¶
/**
* Creates a SELECT SQL-statement
*
* @param string $select_fields See exec_SELECTquery()
* @param string $from_table See exec_SELECTquery()
* @param string $where_clause See exec_SELECTquery()
* @param string $groupBy See exec_SELECTquery()
* @param string $orderBy See exec_SELECTquery()
* @param string $limit See exec_SELECTquery()
* @return string Full SQL query for SELECT
* @access public
*/
public static function SELECTquery( $select_fields, $from_table, $where_clause, $groupBy = '', $orderBy = '', $limit = '' )
Sample¶
$query = \Netzmacher\Refresh\Compatibility\Core\Database\DatabaseConnection::SELECTquery( $select, $from, $where, $groupBy, $orderBy, $limit );
Refresh¶
You can refresh your extension by find and replace.
// Code from TYPO3 6.2 to 8.7
$query = $GLOBALS[ 'TYPO3_DB' ]->SELECTquery( $select, $from, $where, $groupBy, $orderBy, $limit );
// Code from TYPO3 6.2 to 9.x
$query = Netzmacher\Refresh\Compatibility\Core\Database\DatabaseConnection::SELECTquery( $select, $from, $where, $groupBy, $orderBy, $limit );
Move “$GLOBALS[ ‘TYPO3_DB’ ]->SELECTquery” to “Netzmacher\Refresh\Compatibility\Core\Database\DatabaseConnection::SELECTquery”