Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> mime types oas
I'm trying to dump a csv file to clients for them to suck into Excel
This is a test version of the procedure I'm using.
CREATE OR REPLACE PROCEDURE binq_issue_excel( a_sql VARCHAR2 ) AS
C_SEP CONSTANT CHAR(1) := chr(9) ;
BEGIN
OWA_UTIL.mime_header('text/plain',TRUE) ; -- this works
--OWA_UTIL.mime_header('text/csv',TRUE) ; -- this doesn't
HTP.p('one'||C_SEP||'two'||C_SEP||'three'||C_SEP||'four') ;
HTP.p('five'||C_SEP||'six'||C_SEP||'seven'||C_SEP||'eight') ;
END ;
When the mime type is set to 'text/csv' I get a 'document contains no
data' error from my browser.
Going into sql*plus execute binq_issue_excel('dummy') produces these
outputs.
output works
SQL> exec owa_util.showpage
Content-type: text/plain
one two three four five six seven eight
PL/SQL procedure successfully completed.
output doesn't
SQL> exec owa_util.showpage
Content-type: text/csv
one two three four five six seven eight
PL/SQL procedure successfully completed.
OAS 4.0.7 NT 4 sp 3.
Any thoughts/clues ideas would be helpfull.
Received on Thu May 13 1999 - 03:06:32 CDT