In rails, when generating model, migration is created also.
I’m wondering any PHP framework can do it also?
I’m trying Yii framework now, but seems like I need to generate the migration manually first then generate a model. (or even a third step to generate CRUD :-/)
I suggest you try fuelphp framework (http://fuelphp.com) which has excellent scaffold function as well as other amazing functions. It used PHP 5.3.
I believe the old Yii dbmigrations extension is obsolete in favor of Yii’s built-in migration functions available since Yii 1.1.6: http://www.yiiframework.com/doc/guide/1.1/en/database.migration
However, it does seem like the OP may have tried that already as was not happy with the amount of manual work still involved compared to his experience with RoR.
Doctrine 2 has a migrations component. It’s completely separate from the ORM, so you don’t have to be using Doctrine to use this. This is probably the most popular solution right now.
It does require php 5.3 though.