Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Database_Result_Cached is missing 1.9-dev
  • Database_Result_Cached is no longer available in 1.9 ?
    but it is used in query.php and pdo/result.php.

    thanks.
  • HarroHarro
    Accepted Answer
    Correct.

    It has been replaced by Database_PDO_Result and Database_PDO_Cached (for the PDO based drivers) and Database_MySQLi_Result and Database_MySQLi_Cached for the platform specific MySQLi driver (and other similar drivers).

    This evens the functionality between the two types of drivers.
  • Thank you for your reply.

    It's working now.
    maybe it was just after update 1.9-dev from 1.8, so I got old cache.

    thanks!!


    $list = DB::select()
    ->from('...')
    ->cached(60 * 60)
    ->execute()
    This code doesn't work, because the Database_Result_Cached  is used in class Database_Query (query.php line:307) .

    I can use Cache::call instead of Database_Query::cached.
    $list = Cache::call('...', function () {
    return DB::select()
    ->from('...')
    ->execute()
    ->as_array();
    }, array(), 60 * 60);
    it's not urgent, but maybe need fix or somethig to change.

    thanks
  • HarroHarro
    Accepted Answer
    Ah, that is definitely overlooked. Thanks for debugging it!

    Can you make an issue for this at https://github.com/fuel/core/issues ?

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion