大家有没有遇到过mysql5.5中表的分区数量超过1024的问题

starmoonlove 2016-09-14 11:39:49
在mysql5.5中关于分区表最大数量的描述如下:
Maximum number of partitions. The maximum possible number of partitions for a given table (that does not use the NDB storage engine) is 1024. This number includes subpartitions.
请教下大家有没有办法提高这个1024的值。不考虑换更高版本的数据库,比如在mysql5.6的文档里面有描述:
Maximum number of partitions. The maximum possible number of partitions for a given table not using the NDB storage engine is 8192. This number includes subpartitions.
...全文
643 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
starmoonlove 2016-09-19
  • 打赏
  • 举报
回复
引用 3 楼 ACMAIN_CHM 的回复:
升级应该是最简单的方法。
嗯,找了好久没有找到其它方法。
ACMAIN_CHM 2016-09-19
  • 打赏
  • 举报
回复
升级应该是最简单的方法。
starmoonlove 2016-09-19
  • 打赏
  • 举报
回复
引用 楼主 starmoonlove 的回复:
在mysql5.5中关于分区表最大数量的描述如下: Maximum number of partitions. The maximum possible number of partitions for a given table (that does not use the NDB storage engine) is 1024. This number includes subpartitions. 请教下大家有没有办法提高这个1024的值。不考虑换更高版本的数据库,比如在mysql5.6的文档里面有描述: Maximum number of partitions. The maximum possible number of partitions for a given table not using the NDB storage engine is 8192. This number includes subpartitions.
超过1024或者是8192都会报错,我们产品线上的项目,现在已经超过了1024个分区,不能在分了,没有找到好的解决办法,只有升级数据库到5.6,8192个分区总够用了。
LongRui888 2016-09-14
  • 打赏
  • 举报
回复

这个应该是不可以的,你可以试试用脚本生成一大堆的分区,看看如果超过1024,会不会报错。

我个人的猜测是有2种,第一个就是这个所谓最大分区数量,只是一个硬性限制,类似于一个常量,写的就是1024个。

第二个,就是没有那么简单,可能就是整个系统在处理分区表时,就只处理最高的1024个分区表,多了就处理不了了。。。

当然这个只是我个人的猜测。

56,677

社区成员

发帖
与我相关
我的任务
社区描述
MySQL相关内容讨论专区
社区管理员
  • MySQL
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧