Search code examples
yiimigration

Yii Database Migration


Hello guys I am new to yii frame work and I am following larry ullman's instructions on the e-book. The problem I have is: when I'm creating new migration I keep on getting this error

The migration directory does not exists:application.migrations

I use the command : $ yiic migrate create <name>

Thank you guys for helping me understand yii.


Solution

  • I have noticed that the answer for this issue have been answered in the comments section, but may not be noticable for others.

    Just to summarize:

    1. You need to execute the yiic inside the protected directory
    2. There should be an yiic.bat inside the protected directory
    3. In some cases, the migration directory inside the protected directory must be available beforehand and is writable.