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

reverted the fix for Bug#5507

This commit is contained in:
unknown
2007-04-17 12:32:01 +02:00
parent c2951b70d6
commit 5234f5adb7
4 changed files with 14 additions and 53 deletions

View File

@@ -54,33 +54,18 @@ drop table t1;
# End of 4.1 tests
# Test for Bug#5507 "TRUNCATE should work with views"
#
# when it'll be fixed, the error should become 1347
# (test.v1' is not BASE TABLE)
#
create table t1 (s1 int);
insert into t1 (s1) values (1), (2), (3), (4), (5);
create view v1 as select * from t1;
--error 1146
truncate table v1;
select count(*) from t1;
insert into t1 (s1) values (1), (2), (3), (4), (5);
create view v2 as select * from t1 where s1 > 3;
truncate table v2;
select * from t1;
select * from v2;
delete from t1;
# The following should fail
create table t2 (s1 int, s2 int);
create view v3 as select a.s1, b.s2 from t1 a join t2 b on a.s1 = b.s1 where a.s1 > 3;
--error 1395
truncate table v3;
# The following should fail
create view v4 as select * from t1 limit 1,1;
--error 1288
truncate table v4;
drop view v1, v2, v3, v4;
drop table t1, t2;
drop view v1;
drop table t1;
# End of 5.0 tests