// example where I have an extra column counting the number of another model that belong to the base model protected static $_views = array( 'counted' => array( 'columns' => array('transaction_count'), ), );
$logs = Model_Log::query()->use_view('counted')->get();
It looks like you're new here. If you want to get involved, click one of these buttons!