src/CarteBlanche/Library/StorageEngine/DatabaseDriver/SqliteDriver.php
public function query($query = null, $type = null, $method = 'query', $cached = true)
    {
        if (is_null($type)) $type = self::$DBADAPTER_BOTH;

        if ($cached===true && $this->db_driver->isCachedQuery($query))
            return $this->db_driver->getCachedResults( $query );

        $err = null;
        $results = $this->db->{$method}($query, $type, $err);
        if ($err) trigger_error( "Error on query '{$query}' [$err]!", E_USER_ERROR);
        $this->db_driver->addCachedQuery( $query, $results );
        return $results;
    }
public function query($query = null, $type = null, $method = 'query', $cached = true)
    {
        if (is_null($type)) $type = self::$DBADAPTER_BOTH;

        if ($cached===true && $this->db_driver->isCachedQuery($query))
            return $this->db_driver->getCachedResults( $query );

        $err = null;
        $results = $this->db->{$method}($query, $type, $err);
        if ($err) trigger_error( "Error on query '{$query}' [$err]!", E_USER_ERROR);
        $this->db_driver->addCachedQuery( $query, $results );
        return $results;
    }
Execute a query

@param string $query The query string to execute
@param string $type The query type (see php documentation)
@param string $method The query method to use
@param bool $cached If set to TRUE (default), the query results are first searched in the object cache
@return mixed The query result(s)
@see http://www.php.net/manual/en/function.sqlite-query.php