Could someone give me an example of PL/SQL code that would make the following actions:
1. Convert a CLOB from WIN1252 to AL32UTF8,
2. Convert the CLOB to a BLOB,
3. Use WPG_DOCLOAD.DOWNLOAD_FILE to download the BLOB as a XML file.
Thank you.
Printable View
Could someone give me an example of PL/SQL code that would make the following actions:
1. Convert a CLOB from WIN1252 to AL32UTF8,
2. Convert the CLOB to a BLOB,
3. Use WPG_DOCLOAD.DOWNLOAD_FILE to download the BLOB as a XML file.
Thank you.
The following works:
-- CONVERTING THE CLOB TO UNICODE THEN TO BLOB
v_blob := clob_to_blob (NCLOB(v_clob);
htp.p ('Content-length: ' || length(v_blob));
................
OWA_UTIL.http_header_close;
-- Download the file
WPG_DOCLOAD.download_file(v_blob);
......