Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
phpactiverecord
  •     public static $belongs_to = array(
                array('thread', 'class_name' => 'Model_Thread')
        );
    

    When trying to access the related item's rows, it returns and error
    ActiveRecord\DatabaseException [ 42 ]: 42S22, 1054, Unknown column 'modelthread_id' in 'where clause'
    

    It seems to be adding "model" to the column names. not sure if this is a bug or something im doing wrong, as there is not much information regarding the phpactiverecord class for Fuel, (i know the actual site has info but it does not use 'Model_ ')
  • This is not the answer but... The ActiveRecord package is no longer supported, so you might want to check out the new ORM package (http://fuelphp.com/docs/packages/orm/creating_models.html) instead.

Howdy, Stranger!

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

In this Discussion