V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
kenneth
V2EX  ›  Python

求一个Python实现的Mysql分表算法?

  •  
  •   kenneth · 2013-04-26 17:56:47 +08:00 · 3537 次点击
    这是一个创建于 4019 天前的主题,其中的信息可能已经有所发展或是发生改变。
    以及分表后带来的索引的问题,大家一般如何处理?
    求教
    6 条回复    1970-01-01 08:00:00 +08:00
    binux
        1
    binux  
       2013-04-26 18:09:09 +08:00
    如果分表后会有索引问题,那么说明你分错了。。
    explon
        2
    explon  
       2013-04-26 18:12:26 +08:00
    分表跟语言无关
    gaocheng
        3
    gaocheng  
       2013-04-26 19:19:27 +08:00
    分表跟索引有什么关系,每个表的结构都是一样的啊
    lanyueniao
        4
    lanyueniao  
       2013-04-26 23:10:47 +08:00
    murmurhash
    kenneth
        5
    kenneth  
    OP
       2013-04-27 10:50:27 +08:00
    @binux 高手,能否展开一下,这个问题,我还不很明白。
    binux
        6
    binux  
       2013-04-27 11:02:59 +08:00
    @kenneth 一般来说,分表之后,对于一个查询应该能够定位到一个确定的表上,索引该是什么就是什么,没有影响。
    如果有索引问题。。要么是分法不对,要么不应该分。
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   3023 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 13:40 · PVG 21:40 · LAX 06:40 · JFK 09:40
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.