diff --git a/ora/flex_ws_api.pkb b/ora/flex_ws_api.pkb index eea66d9..a2012a3 100755 --- a/ora/flex_ws_api.pkb +++ b/ora/flex_ws_api.pkb @@ -260,6 +260,7 @@ is l_hdr_value varchar2(1024); l_hdr header; l_hdrs header_table; + l_returnvalue xmltype; begin -- determine database characterset, if not AL32UTF8, conversion will be necessary @@ -389,13 +390,17 @@ begin end; utl_http.end_response(l_http_resp); + + begin + l_returnvalue := xmltype.createxml( l_clob ); + exception when others then + if sqlcode = -31011 then -- invalid xml + raise_application_error( -20001, 'HTTP response could not be converted to XML. Response was (first 1000 characters): ' || dbms_lob.substr( l_clob, 1000 )); + end if; + end; + dbms_lob.freetemporary( l_clob ); - return xmltype.createxml(l_clob); - -exception when others then - if sqlcode = -31011 then -- its not xml - return null; - end if; + return l_returnvalue; end make_request; function make_rest_request( diff --git a/ora/xlsx_builder_pkg.pkb b/ora/xlsx_builder_pkg.pkb index 8f4ad26..31345fd 100755 --- a/ora/xlsx_builder_pkg.pkb +++ b/ora/xlsx_builder_pkg.pkb @@ -1,5 +1,5 @@ CREATE OR REPLACE package body xlsx_builder_pkg -as +as -- c_LOCAL_FILE_HEADER constant raw(4) := hextoraw( '504B0304' ); -- Local file header signature c_END_OF_CENTRAL_DIRECTORY constant raw(4) := hextoraw( '504B0506' ); -- End of central directory signature @@ -1624,9 +1624,9 @@ ts timestamp := systimestamp; loop t_xxx := t_xxx || ''; + to_char( nvl( workbook.sheets( s ).autofilters( a ).row_end, workbook.sheets( s ).rows.last() )) || '"/>'; end loop; if workbook.sheets( s ).mergecells.count() > 0 then @@ -1694,7 +1694,7 @@ ts timestamp := systimestamp; t_xxx := t_xxx || ''; if workbook.sheets( s ).comments.count() > 0 then - t_xxx := t_xxx || ''; + t_xxx := t_xxx || ''; end if; -- t_xxx := t_xxx || ''; @@ -1949,6 +1949,7 @@ style="position:absolute;margin-left:35.25pt;margin-top:3pt;z-index:' || to_char then dbms_sql.close_cursor( t_c ); end if; + raise; end; end xlsx_builder_pkg; / diff --git a/ora/xlsx_builder_pkg.pks b/ora/xlsx_builder_pkg.pks index 67f922e..bf656d0 100755 --- a/ora/xlsx_builder_pkg.pks +++ b/ora/xlsx_builder_pkg.pks @@ -1,5 +1,5 @@ create or replace package xlsx_builder_pkg -as +authid current_user as /********************************************** ** ** Author: Anton Scheffer