The CURSOR ain't loading the blob file into APEX_COLLECTION.
Whereas insert into some_table works fine.
Begin
IF not apex_collection.collection_exists('TEMP_COL') then
apex_collection.create_collection('TEMP_COL');
else
apex_collection.truncate_collection('TEMP_COL');
END IF;
for f in (
select FILENAME, MIME_TYPE,BLOB_CONTENT
from apex_application_temp_files
--where application_id = :APP_ID
) loop
apex_collection.add_member
( p_collection_name => 'TEMP_COL'
, p_c001 => f.FILENAME
, p_c002 => f.mime_type
, p_blob001 => f.BLOB_CONTENT
);
end loop;
End;
It throws following error when it used in report query.
select * from APEX_COLLECTIONS.
but if i comment the blob column in the query then it return with the data on report.