在oracle中,如果你想用union去合并不同表中的blob类型的列,如下:
create or replace view skar_all (indnr,text,datei_blob) as
select skim_indnr, skim_text, blob1 from table1
union
select skvt_indnr, skvt_text, blob2 from table2;
结果得到一个错误:
Error report: SQL Error: ORA-00932: inconsistent datatypes: expected - got BLOB
最后查找后得知,union在识别重复项时不支持blob类型,因此只能用union all,所以
create or replace view skar_all (indnr,text,datei_blob) as
select skim_indnr, skim_text, blob1 from table1
union all
select skvt_indnr, skvt_text, blob2 from table2;