I am learning database migration in Yii2. I am trying to create a new migration class create_news_table
using command through composer.
I installed composer globally and running command
yii migrate/create create_news_table
I copied this command from yii2 official site Yii2 Db Migration
But after running command i got this error
Unknown command: migratecreate Did you mean "migrate/create"?
However i have written “migrate/create” not “migratecreate”. Then why it is showing this error?
Advertisement
Answer
I was writing correct syntax. But the problem was with my composer.
I updated composer using composer update
command and now it is working.