|
Server : Apache/2.2.22 (Unix) mod_ssl/2.2.22 OpenSSL/1.0.0-fips mod_auth_passthrough/2.1 mod_bwlimited/1.4 System : Linux server.jackjohnson.com 2.6.32-279.5.2.el6.x86_64 #1 SMP Fri Aug 24 01:07:11 UTC 2012 x86_64 User : jackjohn ( 502) PHP Version : 5.3.17 Disable Function : NONE Directory : /usr/share/mysql-test/t/ |
Upload File : |
# # Test of ansi mode # --disable_warnings drop table if exists t1; --enable_warnings set sql_mode="MySQL40"; select @@sql_mode; set @@sql_mode="ANSI"; select @@sql_mode; # Test some functions that works different in ansi mode SELECT 'A' || 'B'; # Test GROUP BY behaviour CREATE TABLE t1 (id INT, id2 int); SELECT id,NULL,1,1.1,'a' FROM t1 GROUP BY id; #No --error 1055 error due to temporary fix for BUG#8510: #ONLY_FULL_GROUP_BY is overly restrictive, so remove it from ANSI mode. SELECT id FROM t1 GROUP BY id2; drop table t1; SET @@SQL_MODE=""; # Bug#14515 CREATE TABLE t1 (i int auto_increment NOT NULL, PRIMARY KEY (i)); SHOW CREATE TABLE t1; SET @@SQL_MODE="MYSQL323"; SHOW CREATE TABLE t1; SET @@SQL_MODE="MYSQL40"; SHOW CREATE TABLE t1; SET @@SQL_MODE="NO_FIELD_OPTIONS"; SHOW CREATE TABLE t1; DROP TABLE t1; # End of 4.1 tests