protected function createMigrationHistoryTable() { $tableName = $this->db->schema->getRawTableName($this->migrationTable); $this->stdout("Creating migration history table \"{$tableName}\"...", Console::FG_YELLOW); $this->db->createCommand()->createTable($this->migrationTable, ['version' => 'varchar(180) NOT NULL PRIMARY KEY', 'apply_time' => 'integer'])->execute(); $this->db->createCommand()->insert($this->migrationTable, ['version' => self::BASE_MIGRATION, 'apply_time' => time()])->execute(); $this->stdout("Done.\n", Console::FG_GREEN); }