~vkolesnikov/pbxt/pbxt-07-diskfull

« back to all changes in this revision

Viewing changes to pbxt/mysql-test-update/mysql-test/t/ansi.test

  • Committer: paul-mccullagh
  • Date: 2006-10-23 09:14:04 UTC
  • Revision ID: paul-mccullagh-918861e03d351978a9541168a96e58cc826734ee
Initial import

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#
 
2
# Test of ansi mode
 
3
#
 
4
 
 
5
--disable_warnings
 
6
drop table if exists t1;
 
7
--enable_warnings
 
8
 
 
9
set sql_mode="MySQL40";
 
10
select @@sql_mode;
 
11
set @@sql_mode="ANSI";
 
12
select @@sql_mode;
 
13
 
 
14
# Test some functions that works different in ansi mode
 
15
 
 
16
SELECT 'A' || 'B';
 
17
 
 
18
# Test GROUP BY behaviour
 
19
 
 
20
CREATE TABLE t1 (id INT, id2 int);
 
21
SELECT id,NULL,1,1.1,'a' FROM t1 GROUP BY id;
 
22
#No --error 1055 error due to temporary fix for BUG#8510:
 
23
#ONLY_FULL_GROUP_BY is overly restrictive, so remove it from ANSI mode.
 
24
SELECT id FROM t1 GROUP BY id2;
 
25
drop table t1;
 
26
 
 
27
SET @@SQL_MODE="";
 
28
 
 
29
# Bug#14515
 
30
 
 
31
CREATE TABLE t1 (i int auto_increment NOT NULL, PRIMARY KEY (i));
 
32
SHOW CREATE TABLE t1;
 
33
SET @@SQL_MODE="MYSQL323";
 
34
SHOW CREATE TABLE t1;
 
35
SET @@SQL_MODE="MYSQL40";
 
36
SHOW CREATE TABLE t1;
 
37
SET @@SQL_MODE="NO_FIELD_OPTIONS";
 
38
SHOW CREATE TABLE t1;
 
39
DROP TABLE t1;
 
40
 
 
41
# End of 4.1 tests