Bug #29368 Incorrect error, 1467, for syntax error when creating partition
Submitted: 26 Jun 2007 20:50 Modified: 15 Nov 2007 16:26
Reporter: Matthew Lord
Status: Closed
Category:Server: Partition Severity:S3 (Non-critical)
Version:5.1.19 OS:Any
Assigned to: Mattias Jonsson Target Version:
Tags: partitioning, CREATE TABLE

[26 Jun 2007 20:50] Matthew Lord
Description:
 PARTITION p2 VALU ES LESS THAN (1182452400000) causes error 1467.

How to repeat:
CREATE TABLE `foo` (
  `GUID` binary(16) NOT NULL,
  `applicationID` smallint(5) unsigned NOT NULL,
  `startTime` bigint(20) unsigned NOT NULL DEFAULT '0',
  PRIMARY KEY (`GUID`,`startTime`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 PARTITION BY RANGE (startTime) (PARTITION p1 VALUES
LESS THAN (1182441600000) ENGINE = InnoDB, PARTITION p2 VALU
ES LESS THAN (1182452400000) ENGINE = InnoDB);

Suggested fix:
This should cause a standard syntax error as it's very confusing/misleading when
all of the partitions do have VALUES LESS THAN.
[22 Oct 2007 14:54] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/36035

ChangeSet@1.2595, 2007-10-22 14:54:07+02:00, mattiasj@mattiasj-laptop.(none) +4 -0
  Bug#29368: Modified error messages
  New test cases
[10 Nov 2007 13:09] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/37512

ChangeSet@1.2595, 2007-11-10 13:09:18+01:00, mattiasj@mattiasj-laptop.(none) +4 -0
  Bug#29368: Modified error messages
  
  Problem: there was no standard syntax error when
           creating partitions with syntax error in
           the partitioning clause.
  
  Solution: added "Syntax error: " to the error message
[14 Nov 2007 10:41] Bugs System
Pushed into 6.0.4-alpha
[14 Nov 2007 10:45] Bugs System
Pushed into 5.1.23-rc
[15 Nov 2007 16:26] Jon Stephens
Thank you for your bug report. This issue has been committed to our source repository of
that product and will be incorporated into the next release.

If necessary, you can access the source repository and build the latest available
version, including the bug fix. More information about accessing the source trees is
available at

    http://dev.mysql.com/doc/en/installing-source.html

Documented feature addition in 5.1.23 and 6.0.4 changelogs.