Topic > MySQL Partitioning - 1191

MySQL PartitioningPartitioning for MySQL is support for: partitioned file systems and servers and multiple systems and servers for a single database. MySQL partitioning is completed on tables and not on file systems or servers. Table partitioning allows you to store a table across multiple storage areas. MySQL uses row partitioning known as “horizontal partitioning”. As of version 5.5, MySQL does not allow column partitioning known as “vertical partitioning” and is not in development to do so. The "MySQL partitioning engine" is supported by most MySQL-compatible storage engines, however a particular partition must be on the same storage engine for all its instances. the storage engine setting is the same as for a non-partitioned table. But how do you know if your version of MySQL supports partitioning? There are two main ways to check if your version of MySQL supports using partitioning. The first is to use the command “SHOW VARIABLES AS '%partition%';” at the “mysql>” command line prompt. This displays the partitioned variables in the name column of the variable table. The response should be a table with the entry name "have_partitioning" and the corresponding column "YES". The "YES" means that the MySQL version supports partitioning. The second way is to use the “SHOW PLUGINS;” command. at the “mysql>” command line prompt. All plug-ins present and used by your version of MySQL will be displayed. The only plugin to worry about is the “partition” variable in the table. If its status is "ACTIVE", partitioning is enabled for the server. If there is no "partition" plugin, your version does not have partitioning functionality. How do you enable partitioning? Halfway through the document... with questions. Using pruning on a partition table can lead to speedups that are "an order of magnitude" faster than the same table without partitioning. Pruning helps in cases of the "WHERE" statement which controls the entire table. The “IN” command is used as such “column IN (____, ___, …)”. Here it controls only one set of the partition table created by the pruning command. It can also be used in conjunction with WHERE, as in “WHERE _____ IN (___, ___, ___).” The "BETWEEN" statement works similarly to the "IN" statement, as used for pruning. Pruning must: find the minimum value of the partition column, find the maximum value of the partition column, and check the partitions from minimum to maximum inclusively.Works Cited http://dev.mysql.com/doc/refman/5.5/en /partitioning-management .html; Last access March 5, 2010: 11:30 am; © 2010, Oracle Corporation and/or its affiliates