mysql> mysql> use test// Database changed mysql> mysql> mysql> drop table if exists t1// Query OK, 0 rows affected (0.03 sec) mysql> create table t1(f1 char(0), f2 decimal (64) unsigned not null DEFAULT 9.9, f3 tinyint, f5 int)// Query OK, 0 rows affected (0.03 sec) mysql> insert into t1(f2,f3,f5) values(1,1,1),(2,2,2),(3,3,0),(4,4,4),(5,5,5),(6,6,6),(7,7,0),(8,8,8),(9,9,9),(10,10,10)// Query OK, 10 rows affected (0.00 sec) Records: 10 Duplicates: 0 Warnings: 0 mysql> mysql> drop table if exists t2// Query OK, 0 rows affected (0.02 sec) mysql> create table t2(f4 char binary, f5 int)// Query OK, 0 rows affected (0.03 sec) mysql> insert into t2 values('a',1),('a',2),('a',0),('a',4),('a',5),('a',6),('a',0),('a',8),('a',9),('a',10)// Query OK, 10 rows affected (0.00 sec) Records: 10 Duplicates: 0 Warnings: 0 mysql> mysql> drop view if exists v1// Query OK, 0 rows affected, 1 warning (0.00 sec) mysql> create algorithm=merge view v1 as select t1.f1, t1.f2, t1.f3, t2.f4, t2.f5 from t1 inner join t2 using (f5)// Query OK, 0 rows affected (0.00 sec) mysql> drop view if exists v2// Query OK, 0 rows affected, 1 warning (0.00 sec) mysql> create algorithm=merge view v2 as select t1.f1, t1.f2, t1.f3, t2.f4, t2.f5 from t1 inner join t2 using (f5)// Query OK, 0 rows affected (0.00 sec) mysql> drop view if exists v3// Query OK, 0 rows affected, 1 warning (0.00 sec) mysql> create algorithm=merge view v3 as select v1.f1, v1.f2, v1.f3, v2.f4, v2.f5 from v1 inner join v2 using (f5)// Query OK, 0 rows affected (0.02 sec) mysql> mysql> mysql> mysql> select * from v1// +------+----+------+------+------+ | f1 | f2 | f3 | f4 | f5 | +------+----+------+------+------+ | NULL | 1 | 1 | a | 1 | | NULL | 2 | 2 | a | 2 | | NULL | 3 | 3 | a | 0 | | NULL | 7 | 7 | a | 0 | | NULL | 4 | 4 | a | 4 | | NULL | 5 | 5 | a | 5 | | NULL | 6 | 6 | a | 6 | | NULL | 3 | 3 | a | 0 | | NULL | 7 | 7 | a | 0 | | NULL | 8 | 8 | a | 8 | | NULL | 9 | 9 | a | 9 | | NULL | 10 | 10 | a | 10 | +------+----+------+------+------+ 12 rows in set (0.00 sec) mysql> select * from v2// +------+----+------+------+------+ | f1 | f2 | f3 | f4 | f5 | +------+----+------+------+------+ | NULL | 1 | 1 | a | 1 | | NULL | 2 | 2 | a | 2 | | NULL | 3 | 3 | a | 0 | | NULL | 7 | 7 | a | 0 | | NULL | 4 | 4 | a | 4 | | NULL | 5 | 5 | a | 5 | | NULL | 6 | 6 | a | 6 | | NULL | 3 | 3 | a | 0 | | NULL | 7 | 7 | a | 0 | | NULL | 8 | 8 | a | 8 | | NULL | 9 | 9 | a | 9 | | NULL | 10 | 10 | a | 10 | +------+----+------+------+------+ 12 rows in set (0.00 sec) mysql> select * from v3// ERROR 2013 (HY000): Lost connection to MySQL server during query mysql> mysql> mysql> mysql>