Details
-
Bug
-
Status: Closed
-
Critical
-
Resolution: Fixed
-
None
-
None
Description
As shown in the following example, drop table cascade fails to handle a dependent view that has a delimited name. It returns error 1389 complaining that the view (without the double quotes) does not exist. This is a regression introduced in the v0118 build. It was not seen on the v0117 build.
-----------------------------------------------------------------------
Here is the entire script to reproduce this problem:
create schema mytest;
set schema mytest;
create table mytable (a int);
create view "myview" (a) as select a from mytable;
select * from "myview";
showddl "myview";
drop table mytable cascade;
drop view "myview";
drop table mytable cascade;
drop schema mytest cascade;
-----------------------------------------------------------------------
Here is the execution output:
>>obey mytest2.sql;
>>create schema mytest;
— SQL operation complete.
>>set schema mytest;
— SQL operation complete.
>>
>>create table mytable (a int);
— SQL operation complete.
>>create view "myview" (a) as select a from mytable;
— SQL operation complete.
>>select * from "myview";
— 0 row(s) selected.
>>showddl "myview";
CREATE VIEW TRAFODION.MYTEST."myview" (A) AS
SELECT TRAFODION.MYTEST.MYTABLE.A FROM TRAFODION.MYTEST.MYTABLE ;
— SQL operation complete.
>>drop table mytable cascade;
-
-
- ERROR[1389] Object MYVIEW does not exist in Trafodion.
-
— SQL operation failed with errors.
>>
>>drop view "myview";
— SQL operation complete.
>>drop table mytable cascade;
— SQL operation complete.
>>
>>drop schema mytest cascade;
— SQL operation complete.