summaryrefslogtreecommitdiff
path: root/mysql-test/suite/federated
diff options
context:
space:
mode:
authorHe Zhenxing <hezx@mysql.com>2008-09-06 08:51:17 +0800
committerHe Zhenxing <hezx@mysql.com>2008-09-06 08:51:17 +0800
commitb17458dcc14882dcb2565bcbb92115ed786fe7c1 (patch)
tree81eaef221aa476a0279c43f5e5c6df9c91924e44 /mysql-test/suite/federated
parentd0edf322306221f2e662a54a9feecc78378d6dfe (diff)
parentd70d171ceef259920d975fa2ddccaa6a41ba91fe (diff)
downloadmariadb-git-b17458dcc14882dcb2565bcbb92115ed786fe7c1.tar.gz
Merge 5.1 main -> 5.1-rpl
Diffstat (limited to 'mysql-test/suite/federated')
-rw-r--r--mysql-test/suite/federated/federated.result15
-rw-r--r--mysql-test/suite/federated/federated.test38
2 files changed, 42 insertions, 11 deletions
diff --git a/mysql-test/suite/federated/federated.result b/mysql-test/suite/federated/federated.result
index aa0e2cd3119..115f0d5b021 100644
--- a/mysql-test/suite/federated/federated.result
+++ b/mysql-test/suite/federated/federated.result
@@ -1002,13 +1002,13 @@ Warning 1101 BLOB/TEXT column 'blurb' can't have a default value
INSERT INTO federated.t1 VALUES (1, " MySQL supports a number of column types in several categories: numeric types, date and time types, and string (character) types. This chapter first gives an overview of these column types, and then provides a more detailed description of the properties of the types in each category, and a summary of the column type storage requirements. The overview is intentionally brief. The more detailed descriptions should be consulted for additional information about particular column types, such as the allowable formats in which you can specify values.");
INSERT INTO federated.t1 VALUES (2, "All arithmetic is done using signed BIGINT or DOUBLE values, so you should not use unsigned big integers larger than 9223372036854775807 (63 bits) except with bit functions! If you do that, some of the last digits in the result may be wrong because of rounding errors when converting a BIGINT value to a DOUBLE.");
INSERT INTO federated.t1 VALUES (3, " A floating-point number. p represents the precision. It can be from 0 to 24 for a single-precision floating-point number and from 25 to 53 for a double-precision floating-point number. These types are like the FLOAT and DOUBLE types described immediately following. FLOAT(p) has the same range as the corresponding FLOAT and DOUBLE types, but the display size and number of decimals are undefined. ");
-INSERT INTO federated.t1 VALUES(4, "Die Übersetzung einer so umfangreichen technischen Dokumentation wie des MySQL-Referenzhandbuchs ist schon eine besondere Herausforderung. Zumindest für jemanden, der seine Zielsprache ernst nimmt:");
+INSERT INTO federated.t1 VALUES(4, "Die �bersetzung einer so umfangreichen technischen Dokumentation wie des MySQL-Referenzhandbuchs ist schon eine besondere Herausforderung. Zumindest f�r jemanden, der seine Zielsprache ernst nimmt:");
SELECT * FROM federated.t1;
blurb_id blurb
1 MySQL supports a number of column types in several categories: numeric types, date and time types, and string (character) types. This chapter first gives an overview of these column types, and then provides a more detailed description of the properties of the types in each category, and a summary of the column type storage requirements. The overview is intentionally brief. The more detailed descriptions should be consulted for additional information about particular column types, such as the allowable formats in which you can specify values.
2 All arithmetic is done using signed BIGINT or DOUBLE values, so you should not use unsigned big integers larger than 9223372036854775807 (63 bits) except with bit functions! If you do that, some of the last digits in the result may be wrong because of rounding errors when converting a BIGINT value to a DOUBLE.
3 A floating-point number. p represents the precision. It can be from 0 to 24 for a single-precision floating-point number and from 25 to 53 for a double-precision floating-point number. These types are like the FLOAT and DOUBLE types described immediately following. FLOAT(p) has the same range as the corresponding FLOAT and DOUBLE types, but the display size and number of decimals are undefined.
-4 Die Übersetzung einer so umfangreichen technischen Dokumentation wie des MySQL-Referenzhandbuchs ist schon eine besondere Herausforderung. Zumindest für jemanden, der seine Zielsprache ernst nimmt:
+4 Die �bersetzung einer so umfangreichen technischen Dokumentation wie des MySQL-Referenzhandbuchs ist schon eine besondere Herausforderung. Zumindest f�r jemanden, der seine Zielsprache ernst nimmt:
DROP TABLE IF EXISTS federated.t1;
CREATE TABLE federated.t1 (
`a` int NOT NULL,
@@ -2111,6 +2111,17 @@ DROP TABLE t1;
DROP TABLE t1;
CREATE TABLE t1 (a INT) ENGINE=federated CONNECTION='mysql://@:://';
DROP TABLE t1;
+CREATE TABLE t1 (a LONGBLOB, b LONGBLOB);
+INSERT INTO t1 VALUES ('aaaaaaaaaaaaaaaaaaaaaaaaaaaa', NULL);
+CREATE TABLE t1
+(a LONGBLOB, b LONGBLOB) ENGINE=FEDERATED
+CONNECTION='mysql://root@127.0.0.1:SLAVE_PORT/test/t1';
+CHECKSUM TABLE t1;
+Table Checksum
+test.t1 2465757603
+DROP TABLE t1;
+DROP TABLE t1;
+End of 5.0 tests
create server 's1' foreign data wrapper 'mysql' options (port 3306);
drop server 's1';
End of 5.1 tests
diff --git a/mysql-test/suite/federated/federated.test b/mysql-test/suite/federated/federated.test
index 5af3b4560f0..5c88801b032 100644
--- a/mysql-test/suite/federated/federated.test
+++ b/mysql-test/suite/federated/federated.test
@@ -680,7 +680,7 @@ eval CREATE TABLE federated.t1 (
INSERT INTO federated.t1 VALUES (1, " MySQL supports a number of column types in several categories: numeric types, date and time types, and string (character) types. This chapter first gives an overview of these column types, and then provides a more detailed description of the properties of the types in each category, and a summary of the column type storage requirements. The overview is intentionally brief. The more detailed descriptions should be consulted for additional information about particular column types, such as the allowable formats in which you can specify values.");
INSERT INTO federated.t1 VALUES (2, "All arithmetic is done using signed BIGINT or DOUBLE values, so you should not use unsigned big integers larger than 9223372036854775807 (63 bits) except with bit functions! If you do that, some of the last digits in the result may be wrong because of rounding errors when converting a BIGINT value to a DOUBLE.");
INSERT INTO federated.t1 VALUES (3, " A floating-point number. p represents the precision. It can be from 0 to 24 for a single-precision floating-point number and from 25 to 53 for a double-precision floating-point number. These types are like the FLOAT and DOUBLE types described immediately following. FLOAT(p) has the same range as the corresponding FLOAT and DOUBLE types, but the display size and number of decimals are undefined. ");
-INSERT INTO federated.t1 VALUES(4, "Die Übersetzung einer so umfangreichen technischen Dokumentation wie des MySQL-Referenzhandbuchs ist schon eine besondere Herausforderung. Zumindest für jemanden, der seine Zielsprache ernst nimmt:");
+INSERT INTO federated.t1 VALUES(4, "Die �bersetzung einer so umfangreichen technischen Dokumentation wie des MySQL-Referenzhandbuchs ist schon eine besondere Herausforderung. Zumindest f�r jemanden, der seine Zielsprache ernst nimmt:");
SELECT * FROM federated.t1;
connection slave;
@@ -1073,20 +1073,20 @@ SELECT HEX(a) FROM federated.t1;
# CREATE TABLE federated.t1 (a char(20)) charset=cp1251;
# #
# connection master;
-# INSERT INTO federated.t1 values (_cp1251'À-ÁÂÃ-1');
-# INSERT INTO federated.t1 values (_cp1251'Á-ÂÃÄ-2');
+# INSERT INTO federated.t1 values (_cp1251'�-���-1');
+# INSERT INTO federated.t1 values (_cp1251'�-���-2');
# SELECT * FROM federated.t1;
# SET names cp1251;
-# INSERT INTO federated.t1 values ('Â-ÃÄÅ-3');
-# INSERT INTO federated.t1 values ('Ã-ŨÆ-4');
+# INSERT INTO federated.t1 values ('�-���-3');
+# INSERT INTO federated.t1 values ('�-Ũ�-4');
# SELECT * FROM federated.t1;
# SELECT hex(a) from federated.t1;
# SELECT hex(a) from federated.t1 ORDER BY a desc;
-# UPDATE federated.t1 SET a='À-ÁÂÃ-1íîâûé' WHERE a='À-ÁÂÃ-1';
+# UPDATE federated.t1 SET a='�-���-1�����' WHERE a='�-���-1';
# SELECT * FROM federated.t1;
-# DELETE FROM federated.t1 WHERE a='Ã-ŨÆ-4';
+# DELETE FROM federated.t1 WHERE a='�-Ũ�-4';
# SELECT * FROM federated.t1;
-# DELETE FROM federated.t1 WHERE a>'Â-';
+# DELETE FROM federated.t1 WHERE a>'�-';
# SELECT * FROM federated.t1;
# SET names default;
# DROP TABLE IF EXISTS federated.t1;
@@ -1855,9 +1855,29 @@ DROP TABLE t1;
CREATE TABLE t1 (a INT) ENGINE=federated CONNECTION='mysql://@:://';
DROP TABLE t1;
+
#
-# Coverage testing of CREATE SERVER.
+# Bug #34779: crash in checksum table on federated tables with blobs
+# containing nulls
#
+connection slave;
+CREATE TABLE t1 (a LONGBLOB, b LONGBLOB);
+INSERT INTO t1 VALUES ('aaaaaaaaaaaaaaaaaaaaaaaaaaaa', NULL);
+connection master;
+--replace_result $SLAVE_MYPORT SLAVE_PORT
+eval CREATE TABLE t1
+ (a LONGBLOB, b LONGBLOB) ENGINE=FEDERATED
+ CONNECTION='mysql://root@127.0.0.1:$SLAVE_MYPORT/test/t1';
+CHECKSUM TABLE t1;
+connection slave;
+DROP TABLE t1;
+connection master;
+DROP TABLE t1;
+
+connection default;
+
+--echo End of 5.0 tests
+
create server 's1' foreign data wrapper 'mysql' options (port 3306);
drop server 's1';