summaryrefslogtreecommitdiff
path: root/mysql-test/t/dyncol.test
diff options
context:
space:
mode:
authorunknown <sanja@montyprogram.com>2013-08-20 16:23:30 +0300
committerunknown <sanja@montyprogram.com>2013-08-20 16:23:30 +0300
commit9a28e43305bf62e1cef269c395f3ac212c659347 (patch)
tree14c02951bdfa7adf2630762e3432ee9e94acc1f4 /mysql-test/t/dyncol.test
parent0903a40d09a98bb482d2d53530d60eb539753443 (diff)
downloadmariadb-git-9a28e43305bf62e1cef269c395f3ac212c659347.tar.gz
new format length calculation check added.
Diffstat (limited to 'mysql-test/t/dyncol.test')
-rw-r--r--mysql-test/t/dyncol.test11
1 files changed, 11 insertions, 0 deletions
diff --git a/mysql-test/t/dyncol.test b/mysql-test/t/dyncol.test
index 12bb2f0690a..476798a6c7f 100644
--- a/mysql-test/t/dyncol.test
+++ b/mysql-test/t/dyncol.test
@@ -612,6 +612,12 @@ CREATE TABLE t1 (dyn TINYBLOB) ENGINE=MyISAM;
INSERT INTO t1 SET dyn = COLUMN_CREATE( 40, REPEAT('a', 233), 4, REPEAT('b', 322) );
--error ER_DYN_COL_WRONG_FORMAT
SELECT COLUMN_ADD( dyn, 6, REPEAT('x',80), 4, REPEAT('y',215) AS INTEGER ) FROM t1;
+delete from t1;
+--echo #above test with 10.0 format
+INSERT INTO t1 SET dyn = COLUMN_CREATE( 'a', REPEAT('a', 250), 'b', REPEAT('b', 322) );
+--error ER_DYN_COL_WRONG_FORMAT
+SELECT COLUMN_ADD( dyn, 'c', REPEAT('x',80), 'b', REPEAT('y',215) AS INTEGER ) FROM t1;
+
DROP table t1;
@@ -624,6 +630,11 @@ CREATE TABLE t1 (dyncol TINYBLOB) ENGINE=MyISAM;
INSERT INTO t1 SET dyncol = COLUMN_CREATE( 7, REPEAT('k',487), 209, REPEAT('x',464) );
--error 0,ER_DYN_COL_WRONG_FORMAT
SELECT COLUMN_ADD( dyncol, 7, '22:22:22', 8, REPEAT('x',270) AS CHAR ) FROM t1;
+delete from t1;
+INSERT INTO t1 SET dyncol = COLUMN_CREATE( 'a', REPEAT('k',487), 'b', REPEAT('x',464) );
+--error 0,ER_DYN_COL_WRONG_FORMAT
+SELECT COLUMN_ADD( dyncol, 'a', '22:22:22', 'c', REPEAT('x',270) AS CHAR ) FROM t1;
+
DROP table t1;
--echo #