src/NGB/Db/MySQLy/Model.php
public static function select( $clauseWhere = '', $atributos = null ) {
	
		$query = "SELECT ".static::getTable().".* FROM ".static::getTable()." ".$clauseWhere;
	
//print_r($atributos);
		
		if ( null !== $atributos ) {
			
			$a_params[0] = 'lie';
			$strType = '';
			
			if ( is_array($atributos) ) {
				foreach ( $atributos as $k => $v ) {
					$a_params[] = & $atributos[$k];
					
					$strType .= MySQL::getStrType($v);
				}
			}else {
				$a_params[] = & $atributos;
				
				$strType .= MySQL::getStrType($atributos);
			}
			
			$stmt = self::getConexion()->prepare( $query );
			
			$a_params[0] = & $strType;
			//print_r($a_params);
			call_user_func_array(array($stmt, 'bind_param'), $a_params);
		}else {
			$stmt = self::getConexion()->prepare( $query );
		}
		
		self::getConexion()->execute();
		
		$rows = self::getConexion()->fetch_all();
//print_r($rows);exit;
		if ( isset($rows[1]) ) {
			return $rows;
		}else if ( isset($rows[0]) ) {
			$c = get_called_class();
			return new $c( $rows[0] );
		}
		
		return null;
		
	}
public static function select( $clauseWhere = '', $atributos = null ) {
	
		$query = "SELECT ".static::getTable().".* FROM ".static::getTable()." ".$clauseWhere;
	
//print_r($atributos);
		
		if ( null !== $atributos ) {
			
			$a_params[0] = 'lie';
			$strType = '';
			
			if ( is_array($atributos) ) {
				foreach ( $atributos as $k => $v ) {
					$a_params[] = & $atributos[$k];
					
					$strType .= MySQL::getStrType($v);
				}
			}else {
				$a_params[] = & $atributos;
				
				$strType .= MySQL::getStrType($atributos);
			}
			
			$stmt = self::getConexion()->prepare( $query );
			
			$a_params[0] = & $strType;
			//print_r($a_params);
			call_user_func_array(array($stmt, 'bind_param'), $a_params);
		}else {
			$stmt = self::getConexion()->prepare( $query );
		}
		
		self::getConexion()->execute();
		
		$rows = self::getConexion()->fetch_all();
//print_r($rows);exit;
		if ( isset($rows[1]) ) {
			return $rows;
		}else if ( isset($rows[0]) ) {
			$c = get_called_class();
			return new $c( $rows[0] );
		}
		
		return null;
		
	}
@link http://www.pontikis.net/blog/how-to-use-php-improved-mysqli-extension-and-why-you-should
@link http://www.pontikis.net/blog/dynamically-bind_param-array-mysqli

@param string $clauseWhere
@param array|mixed $atributos
@return NULL|resource|\MySQLi_Result