我在使用最新版本的 yii-dbmigration 时遇到了一个新问题,当我运行迁移时,控制台显示以下消息并且迁移不起作用。
$ ./protected/yiic migrate
Migrations directory: protected/migrations/
=== Applying: m20110123200901_create_eav_table =================================
ERROR: m20110123200901_create_eav_table does not have a method named "performTransactional".
迁移代码为:
<?php
class m20110123200901_create_eav_table extends CDbMigration {
public function up() {
$t = $this->newTable('eav');
$t->primary_key('id');
$t->integer('section_id');
$t->integer('entry_id');
$t->integer('field_id');
$t->string('attribute');
$t->text('value');
$t->datetime('created_at');
$t->datetime('updated_at');
$this->addTable($t);
}
public function down() {
$this->removeTable('eav');
}
}
有谁知道会发生什么?
谢谢。
已编辑
大家好,我找到了问题,但我不知道解决方案。
Yii v1.1.7-dev 上出现问题,当我使用另一个版本(如 v1.1.5-dev)时,迁移工作正常。
谁知道怎么修它?
谢谢。