public function selectAll($table, $where = array(), $fields = '*', $order = array(), $limit = 0, $cache = true) {        
        $this->buildSelectQuery(SafeString::makeSafe($table), $where, $fields, $order, $limit);
        $result = $this->executeQuery($cache);
        if(!$result) {
            if($limit === 1) {$result = $this->query->fetch(PDO::FETCH_ASSOC);} // Reduce the memory usage if only one record and increase performance
            else{$result = $this->query->fetchAll(PDO::FETCH_ASSOC);}
            if($cache && $this->cacheEnabled) {$this->setCache($this->key, $result);}
        }
        return $result ? $result : false;
    }