Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Hello
  • Problem with DB Query;
     return $query = \DB::select()->from( 'jobs' )->execute();
    

    Result
     Fuel\Core\Database_MySQL_Result Object ( [_internal_row:protected] => 0 [_query:protected] => SELECT * FROM `jobs` [_result:protected] => Resource id #55 [_total_rows:protected] => 1 [_current_row:protected] => 0 [_as_object:protected] => ) 1
    

    Why i cant retrive data?
  • Hi guys! I am also new to fuelPHP. So... I also have similar issue:
    Fatal error: Cannot access protected property Fuel\Core\Database_MySQL_Result::$_total_rows So... how do I have to set it up for this to work?
  • What are you trying to do? Can you post the code on http://scrp.at and tell us the line that generates that error?
  • You just have. You can foreach over the result object to retrieve the rows. By default it will return the row as an array, you can use ->as_object()->execute(); if you prefer stdclass objects.

Howdy, Stranger!

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

In this Discussion