| Bug #24366 | can't create partition | ||
|---|---|---|---|
| Submitted: | 16 Nov 2006 16:42 | Modified: | 17 Nov 2006 9:29 |
| Reporter: | Aftab Khan | Email Updates: | |
| Status: | Not a Bug | Impact on me: | |
| Category: | MySQL Server | Severity: | S2 (Serious) |
| Version: | 5.1.12 | OS: | Windows (windows) |
| Assigned to: | CPU Architecture: | Any | |
[16 Nov 2006 23:19]
Hartmut Holzgraefe
are you sure that you're running 5.1.12? the statement works fine for me on both 5.1.12 and latest 5.1 source on unix
[17 Nov 2006 0:39]
Hartmut Holzgraefe
I have to revert my previous note, you are probably running a 5.1.12 release which doesn't have partitioning enabled. You can check for this using SHOW PLUGINS; or SELECT * FROM INFORMATION_SCHEMA.PLUGINS WHERE PLUGIN_NAME='partition';
[17 Nov 2006 9:29]
Aftab Khan
I ran the following. SELECT * FROM INFORMATION_SCHEMA.PLUGINS WHERE PLUGIN_NAME='partition'; and I get empty result set. So it means the partition is not enabled; can you please tell me how to enable partition. because its very urgent; I have developed a web based interface for real time database, which receives 10 to 100 records every second and I have developed OLAP type report; but the problem is that the query runs against single table, which has tera bytes of data, for that reason I want to do partition by list option.

Description: I can't create partition either with create table or with alter table, the following example I have copied from mysql online documentation, but it failed. I am stuck, as I need to create list partitions. CREATE TABLE tr (id INT, name VARCHAR(50), purchased DATE) PARTITION BY RANGE( YEAR(purchased) ) ( PARTITION p0 VALUES LESS THAN (1990), PARTITION p1 VALUES LESS THAN (1995), PARTITION p2 VALUES LESS THAN (2000), PARTITION p3 VALUES LESS THAN (2005) ) #1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'PARTITION BY RANGE( YEAR(purchased) ) ( PARTITION p0 VALUES LESS T' at line 2 How to repeat: CREATE TABLE tr (id INT, name VARCHAR(50), purchased DATE) PARTITION BY RANGE( YEAR(purchased) ) ( PARTITION p0 VALUES LESS THAN (1990), PARTITION p1 VALUES LESS THAN (1995), PARTITION p2 VALUES LESS THAN (2000), PARTITION p3 VALUES LESS THAN (2005) ) #1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'PARTITION BY RANGE( YEAR(purchased) ) ( PARTITION p0 VALUES LESS T' at line 2