您好, 欢迎来到 !    登录 | 注册 | | 设为首页 | 收藏本站

php artisan migrate时出现 SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; max key length is 1000 bytes解决办法

bubuko 2022/1/25 20:09:14 其他 字数 1263 阅读 895 来源 http://www.bubuko.com/infolist-5-1.html

在测试队列中运用artisan命令行 php artisan queue:table php artisan migrate时出现 SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; ...
在测试队列中运用artisan命令行
php artisan queue:table

php artisan migrate时出现

SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; max key length is 1000 bytes



Change  database.php which is in config folder where it says

‘charset‘ => ‘utf8mb4‘, ‘collation‘ => ‘utf8mb4_unicode_ci‘, 

I changed these to

‘charset‘ => ‘utf8‘, ‘collation‘ => ‘utf8_unicode_ci‘,

 

php artisan migrate时出现 SQLSTATE[42000]: Syntax error or access violation: 1071 Specified key was too long; max key length is 1000 bytes解决办法

原文:https://www.cnblogs.com/kangshuai/p/12386397.html


如果您也喜欢它,动动您的小指点个赞吧

除非注明,文章均由 laddyq.com 整理发布,欢迎转载。

转载请注明:
链接:http://laddyq.com
来源:laddyq.com
著作权归作者所有。商业转载请联系作者获得授权,非商业转载请注明出处。


联系我
置顶