Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

error on php artisan migrate laravel

Tags:

php

enums

laravel

I am using Laravel and I have migration with function:

public function up()
{
    Schema::table('articles', function (Blueprint $table) {
        $table->string('article_title',100)->change();
    });
}

and when i do 'php artisan migrate' on my cmd i get error:

[Doctrine\DBAL\DBALException] Unknown database type enum requested, Doctrine\DBAL\Platforms\MySqlPlatform may not support it.

I don't even use enum! And I also don't have any other migrations that are not migrated and have enum.

like image 591
Danielius Avatar asked Oct 18 '22 07:10

Danielius


1 Answers

The column itself does not have to be enum, but ANY column in the table cannot be enum.

Here is the line from the renaming columns section of the Laravel documentation:

Note: Renaming columns in a table with a enum column is not currently supported.

like image 121
Rob Fonseca Avatar answered Oct 21 '22 03:10

Rob Fonseca