1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00

sending right error message where VIEW is not expected (BUG#4606)

This commit is contained in:
bell@sanja.is.com.ua
2004-08-24 15:37:51 +03:00
parent ea1df67d33
commit 393e41fe21
5 changed files with 51 additions and 20 deletions

View File

@@ -1047,3 +1047,9 @@ select * from v1;
EXISTS (SELECT 1 UNION SELECT 2)
1
drop view v1;
create table t1 (col1 int,col2 char(22));
create view v1 as select * from t1;
create index i1 on v1 (col1);
ERROR HY000: 'test.v1' is not BASIC TABLE
drop view v1;
drop table t1;

View File

@@ -987,3 +987,13 @@ SHOW TABLES;
CREATE VIEW v1 AS SELECT EXISTS (SELECT 1 UNION SELECT 2);
select * from v1;
drop view v1;
#
# using VIEW where table is required
#
create table t1 (col1 int,col2 char(22));
create view v1 as select * from t1;
-- error 1346
create index i1 on v1 (col1);
drop view v1;
drop table t1;