Mysql partitioning: Difference between revisions

From wikinotes
No edit summary
No edit summary
Line 16: Line 16:


</blockquote><!-- Partitioning Strategies -->
</blockquote><!-- Partitioning Strategies -->
= Partition Introspection =
<blockquote>
<syntaxhighlight lang="mysql">
EXPLAIN PARTITIONS SELECT * FROM users;  # list partitions, partition-key for query
</syntaxhighlight>
</blockquote><!-- Partition Introspection -->

Revision as of 02:21, 8 September 2022

A partitioned table's contents are stored in different locations (ex. different servers).
A partitioning key is passed to a function to determine which partition a row or column should belong to.

Partitions must share the same storage-engine

Partition Methods

horizontal:  rows are partitioned
vertical:    cols are partitioned

Partitioning Strategies

Partition Introspection

EXPLAIN PARTITIONS SELECT * FROM users;  # list partitions, partition-key for query