createSchemaTable example

$this->markMigrationAsFinished($migration);
    }

    /** * Composite Method to apply all migrations * * @param AbstractMigration::MODUS_* $modus */
    public function run($modus = AbstractMigration::MODUS_INSTALL)
    {
        $this->createSchemaTable();

        $currentVersion = $this->getCurrentVersion();
        $this->log(sprintf('Current MigrationNumber: %s', $currentVersion));

        $migrations = $this->getMigrationsForVersion($currentVersion);

        $this->log(sprintf('Found %s migrations to apply', \count($migrations)));

        foreach ($migrations as $migration) {
            $this->log(sprintf('Apply MigrationNumber: %s - %s', $migration->getVersion()$migration->getLabel()));
            try {
                


    /** * @param int $offset * @param int $totalCount * * @return ErrorResult|FinishResult|ValidResult */
    public function run($offset$totalCount = null)
    {
        if ($offset == 0) {
            $this->migrationManager->createSchemaTable();
        }

        $currentVersion = $this->migrationManager->getCurrentVersion();

        if (!$totalCount) {
            $totalCount = \count($this->migrationManager->getMigrationsForVersion($currentVersion));
        }

        $migration = $this->migrationManager->getNextMigrationForVersion($currentVersion);

        if ($migration === null) {
            
Home | Imprint | This part of the site doesn't use cookies.