原文:django.db.utils.OperationalError: (1071, 'Specified key was too long; max key length is 767 bytes')

環境介紹 Django . Python . . mysqlclient . . .post Mysql . . RHEL . 在migrate時候報錯 model代碼如下 這個表在migrate時候出現BLOB TEXT column id used in key specification without a key length BLOB TEXT不能被用作索引,所以報錯 於是修改key字段 ...

2019-04-27 15:14 0 669 推薦指數:

查看詳情

Specified key was too long; max key length is 767 bytes

這個異常是索引長度超出限制 767個字節。 在測試環境部署flowable時,程序創建flowable表時,出現了【Specified key was too long; max key length is 767 bytes】異常。 這個異常在開發環境是沒有的,也就是說 ...

Wed Jul 15 19:25:00 CST 2020 0 1274
 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM