Test alter_table_drop_column.Bug-6749.py (id 3c6cbe78e1fe) (err)
alter_table_drop_column.Bug-6749.stable.out.FILTERED 2019-09-08 13:25:24.111456500 +0200alter_table_drop_column.Bug-6749.test.out.FILTERED 2019-09-08 13:25:24.127066100 +0200
..................
# .L54 # table_name
171 % L # name 171 127 % L # name 127
172 # L54 # name 172 ! 128 # L34 # name 128
173 % bigint # type 173 129 % bigint # type 129
174 % 1 # length 174 130 % 1 # length 130
175 [ 2 ] 175 ! 131 [ 0 ] 131
176 #drop table t;start transaction;create table t (a int, b int, c int);alter table t add unique (b);select * from t;select count(*) from objects inner join dependencies on objects.id = dependencies.depend_id inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select count(*) from dependencies inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select keys.type, keys.name, keys.rkey, keys.action from keys inner join tables on tables.id = keys.table_id where tables.name = 't';select idxs.type, idxs.name from idxs inner join tables on tables.id = idxs.table_id where tables.name = 't';alter table t drop column b cascade;select count(*) from objects inner join dependencies on objects.id = dependencies.depend_id inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select count(*) from dependencies inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select keys.type, keys.name, keys.rkey, keys.action from keys inner join tables on tables.id = keys.table_id where tables.name = 't';select idxs.type, idxs.name from idxs inner join tables on tables.id = idxs.table_id where tables.name = 't';select * from t;commit;select * from t;drop table t; 176 132 #drop table t;start transaction;create table t (a int, b int, c int);alter table t add unique (b);select * from t;select count(*) from objects inner join dependencies on objects.id = dependencies.depend_id inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select count(*) from dependencies inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select keys.type, keys.name, keys.rkey, keys.action from keys inner join tables on tables.id = keys.table_id where tables.name = 't';select idxs.type, idxs.name from idxs inner join tables on tables.id = idxs.table_id where tables.name = 't';alter table t drop column b cascade;select count(*) from objects inner join dependencies on objects.id = dependencies.depend_id inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select count(*) from dependencies inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select keys.type, keys.name, keys.rkey, keys.action from keys inner join tables on tables.id = keys.table_id where tables.name = 't';select idxs.type, idxs.name from idxs inner join tables on tables.id = idxs.table_id where tables.name = 't';select * from t;commit;select * from t;drop table t; 132
..................
# .L54 # table_name
179 % L # name 179 135 % L # name 135
180 # L54 # name 180 ! 136 # L32 # name 136
181 % bigint # type 181 137 % bigint # type 137
182 % 1 # length 182 138 % 1 # length 138
183 [ 2 ] 183 ! 139 [ 0 ] 139
184 #drop table t;start transaction;create table t (a int, b int, c int);alter table t add unique (b);select * from t;select count(*) from objects inner join dependencies on objects.id = dependencies.depend_id inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select count(*) from dependencies inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select keys.type, keys.name, keys.rkey, keys.action from keys inner join tables on tables.id = keys.table_id where tables.name = 't';select idxs.type, idxs.name from idxs inner join tables on tables.id = idxs.table_id where tables.name = 't';alter table t drop column b cascade;select count(*) from objects inner join dependencies on objects.id = dependencies.depend_id inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select count(*) from dependencies inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select keys.type, keys.name, keys.rkey, keys.action from keys inner join tables on tables.id = keys.table_id where tables.name = 't';select idxs.type, idxs.name from idxs inner join tables on tables.id = idxs.table_id where tables.name = 't';select * from t;commit;select * from t;drop table t; 184 140 #drop table t;start transaction;create table t (a int, b int, c int);alter table t add unique (b);select * from t;select count(*) from objects inner join dependencies on objects.id = dependencies.depend_id inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select count(*) from dependencies inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select keys.type, keys.name, keys.rkey, keys.action from keys inner join tables on tables.id = keys.table_id where tables.name = 't';select idxs.type, idxs.name from idxs inner join tables on tables.id = idxs.table_id where tables.name = 't';alter table t drop column b cascade;select count(*) from objects inner join dependencies on objects.id = dependencies.depend_id inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select count(*) from dependencies inner join columns on dependencies.id = columns.id inner join tables on columns.table_id = tables.id where tables.name = 't';select keys.type, keys.name, keys.rkey, keys.action from keys inner join tables on tables.id = keys.table_id where tables.name = 't';select idxs.type, idxs.name from idxs inner join tables on tables.id = idxs.table_id where tables.name = 't';select * from t;commit;select * from t;drop table t; 140