Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: XMLQuery select gives "PLS-00801: internal error"

Re: XMLQuery select gives "PLS-00801: internal error"

From: stephen O'D <stephen.odonnell_at_gmail.com>
Date: 26 Mar 2006 11:14:07 -0800
Message-ID: <1143400447.097204.317780@g10g2000cwb.googlegroups.com>

Gerry Atric wrote:

> I take it this means Oracle does not do implicit casting between xmltype and
> varchar2? I don't see why this is not possible... an implicit cast could
> just copy the xmltype stuctured data into a varchar2 (or clob).
>
> The version is Oracle 10gR2 Standard running on RHAS4.
>
> ---------------------
>
> "Error(71,2): PLS-00801: internal error [*** ASSERT at file pdw4.c, line
> 793; Cannot coerce between type 43 and type 30;"
>
> --------------------
>
> procedure xmltest as
>
> xmldata xmltype := xmltype('<packet><data>some data</data></packet>');
> xmlresult varchar2(4000);
>
> begin
>
> select xmlquery('for $a in $doc/packet/data return <data>{$a}</data>'
> passing xmldata as "doc" returning content) into xmlresult from dual;
>
> end;
>
> -------------------

No it does not. You have to call the getstringval method on it.

xmldata.getstringval(); Received on Sun Mar 26 2006 - 13:14:07 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US