Kien La
Sun Feb 13 13:43:59 -0500 2011
Not supported at this time.
Zoran Ivancevic
Sat Mar 19 01:58:47 -0400 2011
Is there any workaround?
I haven't used this library before, but as much I can see exactly what I'm looking for.
Unfortunately I really need inheritance in the db, for generalizations like (User->Customer,Employee,Admin...).
There are too much differences to keep all in single table.
For example, would something like this work?
Tables: USER CUSTOMER
clas User extends ActiveRecord\Model{
}
class Customer extends User{
static $primary_key = 'user_id';
static $belongs_to = array(array('user'));
}
$customer = Customer::first();
echo $customer->name;
echo $customer->birthday;
(1-2/2)
Subject: Does php-activerecord support single table inheritance strategy
Hi there,
i want to khow if php-activerecord support single table inheritance strategy.
So that we can fetch data from table without specifying the discriminator value as a condition in the find call.
Or it is not supported yet ? thanks you php-activerecord team for the feedbacks and the great job you have done.