src/mysql.php
public static function select($type, $sql, $binds=null) {
	if (in_array($type, self::$types) == false) {
		$exception = bootstrap::get_library('exception');
		throw new $exception('unknown select type');
	}
	
	$results = self::query($sql, $binds);
	return self::{'as_'.$type}($results);
}
public static function select($type, $sql, $binds=null) {
	if (in_array($type, self::$types) == false) {
		$exception = bootstrap::get_library('exception');
		throw new $exception('unknown select type');
	}
	
	$results = self::query($sql, $binds);
	return self::{'as_'.$type}($results);
}
public static function select ( $ type , $ sql , $ binds = null ) { if ( in_array ( $ type , self :: $ types ) == false ) { $ exception = bootstrap :: get_library ( 'exception' ) ; throw new $ exception ( 'unknown select type' ) ; } $ results = self :: query ( $ sql , $ binds ) ; return self :: { 'as_' . $ type } ( $ results ) ; }
executes a SELECT statement, and returns the result as array, row, or single field

@param  string $type  one of the ::AS_* consts
@param  string $sql   the base sql statement
@param  array  $binds bind values for the given sql, @see ::merge()
@return array         result set
executes a SELECT statement and returns the result as array row or single field