summaryrefslogtreecommitdiff
path: root/mysql-test/t/partition_error.test
diff options
context:
space:
mode:
authorunknown <mikael@dator5.(none)>2006-06-23 01:25:24 -0400
committerunknown <mikael@dator5.(none)>2006-06-23 01:25:24 -0400
commiteb160d2836d9b0cc1a28a1bf4d0e3f987b7e7d3d (patch)
tree8f79371ecaf195acb60865be67d098161b038afe /mysql-test/t/partition_error.test
parent54b38dd6b514a4a683dfd5376be3cb70b45b9a20 (diff)
parent604227e855b874b72541703f439b4b24f9cf142e (diff)
downloadmariadb-git-eb160d2836d9b0cc1a28a1bf4d0e3f987b7e7d3d.tar.gz
Merge dator5.(none):/home/pappa/clean-mysql-5.1
into dator5.(none):/home/pappa/bug18198 mysql-test/r/partition.result: Auto merged mysql-test/r/partition_error.result: Auto merged mysql-test/t/partition.test: Auto merged mysql-test/t/partition_error.test: Auto merged sql/sql_table.cc: Auto merged
Diffstat (limited to 'mysql-test/t/partition_error.test')
-rw-r--r--mysql-test/t/partition_error.test22
1 files changed, 22 insertions, 0 deletions
diff --git a/mysql-test/t/partition_error.test b/mysql-test/t/partition_error.test
index d0e3f355292..a9efbc587be 100644
--- a/mysql-test/t/partition_error.test
+++ b/mysql-test/t/partition_error.test
@@ -9,6 +9,28 @@ drop table if exists t1;
--enable_warnings
#
+# Bug 18198: Partitions: Too flexible functions
+#
+-- error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED
+create table t1 (a int)
+partition by range (a)
+(partition p0 values less than ((select count(*) from t1)));
+-- error 1054
+create table t1 (a int)
+partition by range (a)
+(partition p0 values less than (a);
+
+create table t1 (a int)
+partition by range (a)
+(partition p0 values less than (1));
+-- error 1054
+alter table t1 add partition (partition p1 values less than (a));
+-- error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED
+alter table t1 add partition
+(partition p1 values less than ((select count(*) from t1)));
+drop table t1;
+
+#
# Bug 20397: Partitions: Crash when using non-existing engine
#
create table t1 (a int)