Powered By Blogger

Selasa, 04 Maret 2014

How To Show Blob Image Data from Oracle Database in RTF File Using BI Publisher

Hello guys,
now i just wanna share my little tips to show Blob Image data in RTF File using BI Publisher.
The steps are :

1. Create a function to decode BLOB Image data into CLOB data

CREATE OR REPLACE FUNCTION APPS.getbase64( p_source BLOB )
RETURN CLOB
IS
v_result CLOB;
BEGIN
DBMS_LOB.createtemporary(lob_loc => v_result, CACHE => FALSE, dur => 0);
Wf_Mail_Util.EncodeBLOB ( p_source, v_result);
RETURN ( v_result );

END getbase64;

2. Use the function created before in report query with the Blob Image data as parameter that can be retrieve from FND_LOBS table, 'FIELD_DATA' column
example :

Select getbase64(fl.file_data) as “IMAGE_CLOB”
From fnd_lobs fl
Where . . . . . .

3. Show it in RTF file using this below script 

<fo:instream-foreign-object content-type=”image/jpg”><xsl:value-of select=”.//IMAGE_CLOB”/></fo:instream-foreign-object>

Perhaps, it can be useful for you guys.
Thanks


Salam Black_id's Zone :)

Tidak ada komentar:

Posting Komentar