public static function select(
        $fields,
        $tableNames,
        $whereClause = '',
        $groupBy = '',
        $orderBy = '',
        $limit = ''
    ) {
        if ($tableNames === '') {
            throw new \InvalidArgumentException('The table names must not be empty.', 1331488261);
        }
        if ($fields === '') {
            throw new \InvalidArgumentException('$fields must not be empty.', 1331488270);
        }

        self::enableQueryLogging();
        $dbResult = self::getDatabaseConnection()->exec_SELECTquery(
            $fields,
            $tableNames,
            $whereClause,
            $groupBy,
            $orderBy,
            $limit
        );
        if (!$dbResult) {
            throw new \Tx_Oelib_Exception_Database();
        }

        return $dbResult;
    }
public static function select(
        $fields,
        $tableNames,
        $whereClause = '',
        $groupBy = '',
        $orderBy = '',
        $limit = ''
    ) {
        if ($tableNames === '') {
            throw new \InvalidArgumentException('The table names must not be empty.', 1331488261);
        }
        if ($fields === '') {
            throw new \InvalidArgumentException('$fields must not be empty.', 1331488270);
        }

        self::enableQueryLogging();
        $dbResult = self::getDatabaseConnection()->exec_SELECTquery(
            $fields,
            $tableNames,
            $whereClause,
            $groupBy,
            $orderBy,
            $limit
        );
        if (!$dbResult) {
            throw new \Tx_Oelib_Exception_Database();
        }

        return $dbResult;
    }
public static function select ( $ fields , $ tableNames , $ whereClause = '' , $ groupBy = '' , $ orderBy = '' , $ limit = '' ) { if ( $ tableNames === '' ) { throw new \ InvalidArgumentException ( 'The table names must not be empty.' , 1331488261 ) ; } if ( $ fields === '' ) { throw new \ InvalidArgumentException ( '$fields must not be empty.' , 1331488270 ) ; } self :: enableQueryLogging ( ) ; $ dbResult = self :: getDatabaseConnection ( ) -> exec_SELECTquery ( $ fields , $ tableNames , $ whereClause , $ groupBy , $ orderBy , $ limit ) ; if ( ! $ dbResult ) { throw new \ Tx_Oelib_Exception_Database ( ) ; } return $ dbResult ; }
Executes a SELECT query.

@param string $fields list of fields to select, may be "*", must not be empty
@param string $tableNames comma-separated list of tables from which to select, must not be empty
@param string $whereClause WHERE clause, may be empty
@param string $groupBy GROUP BY field(s), may be empty
@param string $orderBy ORDER BY field(s), may be empty
@param string $limit LIMIT value ([begin,]max), may be empty

@return \mysqli_result MySQLi result object

@throws \InvalidArgumentException
@throws \Tx_Oelib_Exception_Database if an error has occurred
Executes a SELECT query .