I just try to extend the length of slug in Tags table as I need to store long slug of tags.
However when I create a migration file like this:
'up' => function (Builder $schema) {
$schema->table('tags', function (Blueprint $table) {
$table->string('slug', 200)->change();
});
},
It shows an error as below:
Syntax error or access violation: 1071 Specified key was too long; max key length is 767 bytes
I tried to change
public static $defaultStringLength = 255; to 191 but it still works uncorrect.
I tried to modify color column from 50 to 300 and it works correct.
Anyone can tell me why (string)color can be extended but (string)slug cannot?
Thank you very much and merry chrismas.