Re: please help: extracting clob data contains XML

From: Vladimir M. Zakharychev <bob_at_dpsp-yes.com>
Date: Thu, 26 Sep 2002 13:20:37 +0400
Message-ID: <amujk9$3iu$1_at_babylon.agtel.net>


> 1) trim all the spaces in the xml_map? would this even help and how
> do i do this w/ clob ?
>
Don't think this will help. Besides, you may destroy mandatory whitespace and your document will be corrupted.

> 2) break up and substr the clob by 32767 chunks but i can't find any
> documentation on how to do this? any dbms_lob packages does this?
>

dbms_lob.substr() naturally.

> 3) is the 32767 linesize even the problem? or is there any
> enviroment variable I can manipulate to let me get the entire xml
> data?

This is PL/SQL limit for VARCHAR2 type. You cannot read more into a buffer variable and you cannot pass more to any PL/SQL procedure. When writing with UTL_FILE.put(), do not forget to fflush() regularly, otherwise its internal buffer will overflow. put_line() is not welcome here as it may add a new line in the wrong place, corrupting the document.

If you have XDK installed, you may also use XMLDocumentCover.writeToFile() to save a document to file. XMLDocumentCover is a package installed as part of XDK and is a PL/SQL cover for corresponding Java XMLDocument class. You may download the latest XDK from http://otn.oracle.com/tech/xml/xdkhome.html

-- 
Vladimir Zakharychev (bob_at_dpsp-yes.com)                http://www.dpsp-yes.com
Dynamic PSP(tm) - the first true RAD toolkit for Oracle-based internet applications.
All opinions are mine and do not necessarily go in line with those of my employer.
Received on Thu Sep 26 2002 - 11:20:37 CEST

Original text of this message