The normal way to delete a custom file type is(dql):
delete <type_name>(all) object;
drop type <type_name>;
if when excuting the above statement,an error which says"Attempt to remove type<type_name> , which still has objects",you can excute this statement to get all the hidden objects: select * from <type name> (all) where i_is_deleted=1 or a_is_hidden=1
The following is the last way to delete a custom file type.(sql)
delete from dm_sysobject_r where r_object_id in (select r_object_id from dm_sysobject_s where r_object_type='<type name>');
delete from dm_type_r where r_object_id in (select r_object_id from dm_type_s where name='<type name>');
delete from dmi_dd_common_info_r where r_object_id in (select r_object_id from dmi_dd_common_info_s where type_name = '<type name>');
delete from dmi_object_type where r_object_id in (select r_object_id from dm_sysobject_s where r_object_type='<type name>');
delete from dmi_type_info_r where r_object_id in (select r_object_id from dmi_type_info_s where r_type_name='<type name>');
delete from dmi_type_info_s where r_type_name='<type name>';
delete from dmi_dd_common_info_s where type_name = '<type name>';
delete from dm_type_s where name='<type name>';
delete from dm_sysobject_s where r_object_type='<type name>';
drop table <type name>_r;
drop table <type name>_s;
BTW,as a plus: turn API trace on: apply,c,NULL,SQL_TRACE,LEVEL,I,1
delete <type_name>(all) object;
drop type <type_name>;
if when excuting the above statement,an error which says"Attempt to remove type<type_name> , which still has objects",you can excute this statement to get all the hidden objects: select * from <type name> (all) where i_is_deleted=1 or a_is_hidden=1
The following is the last way to delete a custom file type.(sql)
delete from dm_sysobject_r where r_object_id in (select r_object_id from dm_sysobject_s where r_object_type='<type name>');
delete from dm_type_r where r_object_id in (select r_object_id from dm_type_s where name='<type name>');
delete from dmi_dd_common_info_r where r_object_id in (select r_object_id from dmi_dd_common_info_s where type_name = '<type name>');
delete from dmi_object_type where r_object_id in (select r_object_id from dm_sysobject_s where r_object_type='<type name>');
delete from dmi_type_info_r where r_object_id in (select r_object_id from dmi_type_info_s where r_type_name='<type name>');
delete from dmi_type_info_s where r_type_name='<type name>';
delete from dmi_dd_common_info_s where type_name = '<type name>';
delete from dm_type_s where name='<type name>';
delete from dm_sysobject_s where r_object_type='<type name>';
drop table <type name>_r;
drop table <type name>_s;
BTW,as a plus: turn API trace on: apply,c,NULL,SQL_TRACE,LEVEL,I,1