Hi All. I am a first time user of Phalcon and I have a question about the Model part of Phalcon.
Consider this query "SELECT user_id, first_name, last_name, totalSalesFigure(user_id) as sales_figure FROM users "; totalSalesFigure is a stored function on the database.
Is there anyway to load the query in the model USERS itself and reference it like this? $user = Users::findFirst('user_id = 3'); // loads the user with user_id = 3 echo $user->sales_figure; // outputs the salesFigure of this user.