开发者

in mysql, does quantity of data in one table affect performance

开发者 https://www.devze.com 2022-12-11 14:56 出处:网络
Setting up a new database that h开发者_Go百科as a comments table. I\'ve been told to expect this table to get extremely large. I\'m wondering if there is any particular reason why I wouldn\'t want to

Setting up a new database that h开发者_Go百科as a comments table. I've been told to expect this table to get extremely large. I'm wondering if there is any particular reason why I wouldn't want to keep this table in the same database as the rest of the data for the site.


Quantity of data will certainly affect performance in any RDBMS, however, there's no reason that this table should exist in a separate database on the same server. If the table truly will become very large with a lot of insert activity, then you might want to consider an ETL process that keeps an indexed copy for fast selection (mostly because indexes can negatively affect inserts despite the performance gain on selects)


Keep the table in the same database for now, but it is well known that insert speed slows as the number of records increases.

There are some options to consider if the performance becomes unacceptable, for instance, if the data can be partitioned, split it across multiple tables in separate databases.

0

精彩评论

暂无评论...
验证码 换一张
取 消