MySQL Forums
Forum List  »  Partitioning

Re: partitioning
Posted by: Phil Hildebrand
Date: August 29, 2008 09:39AM

Since you need an int to partition with MySQL currently, it might be difficult to set that up outside of modifying your schema.

If it's straight forward to modify your schema, you could add an integer column related to the first letter of the user name (1=a, 2=b, etc) and then add that to the primary key, and use a list partition.

Your other option would be to add user name to the primary key (if it's not already), and then use a key partition, which will do a hash on the primary key. This won't guarantee all a's being in the same partition, but it will give you the ability to create 40 partitions and allow MySQL to chose the partitions for you.

Options: ReplyQuote

Written By
August 27, 2008 07:20AM
Re: partitioning
August 29, 2008 09:39AM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.