Skip to Main Content

DevOps, CI/CD and Automation

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Convert XMLType to Varchar2

519943Jun 23 2006 — edited Jun 24 2006
How can I convert an XMLType variable to a Varchar2 variable.
I am doing the following.

DECLARE v_xml XMLType;
v_value varchar2(200);

BEGIN

SELECT XMLELEMENT("Phone",'9999999999')
INTO v_xml
FROM Dual;

END;

I need to convert the value of v_xml to varchar2 and display using DBMS_OUTPUT.PUT_LINE.

Thanks
RK
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 22 2006
Added on Jun 23 2006
1 comment
14,071 views