We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

select columns and call method in model

Select columns in sql query has so effect in query speed. but in phalcon when we select columns can't use model functions and ...

how can solve this problem ?

Basically you can't. When you select only specific columns, that means the data you want is a subset of the complete record. Therefore you are, by definition, not wanting the whole record - which is what a model is a representation of.

If you want to use model methods - don't specify any columns. Like you said, it doesn't really have any effect on query speed.

Thank you Dylan,

Select all columns has effect in query speed. I think an option that solve this problem is good.