Saturday, January 20, 2007

 

XMLQuery

Sample of using XMLQuery

select
XMLQuery(
'for $i in /DOK/CommRecord
where $i/CommType != "EMAIL"
order by $i/CommType
return $i/CommDate'
passing by value XMLType('<DOK>
<CommRecord>
<CommType>LETTER</CommType>
<CommDate>3/12/2005</CommDate>
<CommText>Dear Mr Jackson</CommText>
</CommRecord>
<CommRecord>
<CommType>PHONE</CommType>
<CommDate></CommDate>
<CommText>Dear Ms Potter</CommText>
</CommRecord>
<CommRecord>
<CommType>EMAIL</CommType>
<CommDate>3/11/2005</CommDate>
<CommText>Dear Mr Smith</CommText>
</CommRecord>
</DOK>')
returning content) XDetails
from dual
/

Comments: Post a Comment



<< Home

This page is powered by Blogger. Isn't yours?