I simply cannot understand when or in what situation will we ever choose vertical partitioning instead of horizontal partitioning.
我无法理解我们何时或在什么情况下会选择垂直分区而不是水平分区。
What are the benefits of vertical partitioning VS horizontal partitioning?
垂直分区和水平分区的好处是什么?
Are there any examples of websites / companies / anyone that uses vertical partitioning and what is/will be the main reason for that decision?
有网站/公司/任何人使用垂直分区的例子吗?这一决定的主要原因是什么?
2 个解决方案
#1
9
The main reason to have vertical partition is when there are columns in the table that are updated more often than the rest. You separate them in another table / partition, and when you are performing updates, you do not update the rest of the table. Example can be the posts counter. If it is in the same table as the other user data, each update of the counter (and there are lots) will lock the entire record, but you need to read it often. In vertical partitioning, the updated table will be user_counters, and the performance of users won't be affected of the number of updates.
具有垂直分区的主要原因是,当表中有比其他列更新得更频繁的列时。在另一个表/分区中分离它们,当执行更新时,不更新表的其余部分。示例可以是posts计数器。如果它与其他用户数据位于同一个表中,那么计数器的每次更新(有很多)将锁定整个记录,但您需要经常读取它。在垂直分区中,更新后的表将是user_counter,用户的性能不会受到更新数量的影响。
#2
0
I totally agree with what Darhazer has said. "An example of vertical partitioning might be a table that contains a number of very wide text or BLOB columns that aren't addressed often being broken into two tables that has the most referenced columns in one table and the seldom-referenced text or BLOB data in another". As said in this link : http://dev.mysql.com/tech-resources/articles/partitioning.html
我完全同意达哈泽的话。“垂直分区的一个例子可能是一个包含许多非常宽的文本或BLOB列的表,它们通常被分解为两个表,其中一个表中引用最多的列,另一个表中引用较少的文本或BLOB数据。”正如在这个链接中所说:http://dev.mysql.com/techresources/articles/partition.html
#1
9
The main reason to have vertical partition is when there are columns in the table that are updated more often than the rest. You separate them in another table / partition, and when you are performing updates, you do not update the rest of the table. Example can be the posts counter. If it is in the same table as the other user data, each update of the counter (and there are lots) will lock the entire record, but you need to read it often. In vertical partitioning, the updated table will be user_counters, and the performance of users won't be affected of the number of updates.
具有垂直分区的主要原因是,当表中有比其他列更新得更频繁的列时。在另一个表/分区中分离它们,当执行更新时,不更新表的其余部分。示例可以是posts计数器。如果它与其他用户数据位于同一个表中,那么计数器的每次更新(有很多)将锁定整个记录,但您需要经常读取它。在垂直分区中,更新后的表将是user_counter,用户的性能不会受到更新数量的影响。
#2
0
I totally agree with what Darhazer has said. "An example of vertical partitioning might be a table that contains a number of very wide text or BLOB columns that aren't addressed often being broken into two tables that has the most referenced columns in one table and the seldom-referenced text or BLOB data in another". As said in this link : http://dev.mysql.com/tech-resources/articles/partitioning.html
我完全同意达哈泽的话。“垂直分区的一个例子可能是一个包含许多非常宽的文本或BLOB列的表,它们通常被分解为两个表,其中一个表中引用最多的列,另一个表中引用较少的文本或BLOB数据。”正如在这个链接中所说:http://dev.mysql.com/techresources/articles/partition.html