Check if a copy of your blob was inserted in to system.attach_data table. Also Check the current value for system.mail_attach_seq sequence This will give an idea where the exeption has occured : Hi, : I'm trying to attach an internal BLOB to an email message : by running the following sql statements: create table vtn_blob_table : (blob_index number(8), : blob_col BLOB, : PRIMARY KEY (blob_index) : using index tablespace indexspace) : tablespace wrmsdata : pctfree 10 : pctused 80 : storage (initial 256k next 128k) : / : insert into vtn_blob_table : values (1, utl_raw.cast_to_raw('test BLOB')); : commit; : DECLARE : attach_id INTEGER; : ret_code INTEGER; : ablob BLOB; : BEGIN : SELECT blob_col : INTO ablob : FROM vtn_blob_table : WHERE blob_index = 1; : attach_id := Attach_Data(NULL, 1, 'testablob', ablob); : if (attach_id < 1) then : ret_code := send_mail('vnguyen@ocwd.com', : 'Attach_id < 1', : 'DB Mail: Attach_id < 1', : 'vnguyen@ocwd.com'); : else : ret_code := send_mail('vnguyen@ocwd.com', : 'Test message with attachments', : 'This message has one attachment.', : NULL, : NULL, : NULL, : attach_id) ; : end if; : END; : / : and what I have received was the 'Attach_id < 1' message : without the attachment. I know that I'm having problem : with the attach_data function. Please help!!! : Thank you, : Vickie
|