Skip to Main Content

Integration

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!

OSB - XQuery - line 7, col 2: {err}FORG0005: expected exactly 1 item, got 0

877991Aug 1 2011 — edited Aug 4 2011
Hi,

I am trying to execute the below sample XQuery. Eclipse designer does not show any error. However on executing the XQuery, I get the following error "+Error executing the XQuery transformation: line 7, column 2: {err}FORG0005: expected exactly one item, got 0 items+". Appreciate your help.


xquery version "1.0" encoding "UTF-8";

declare namespace xf = "http://tempuri.org/OSB%20Project%201/Ids/";

declare function xf:Ids()
as element() {*
* let $abc := <catalog><product dept="MEN"><number>784</number><name language="en">Cotton Dress Shirt</name><colorChoices>white gray</colorChoices><desc>Our favorite shirt!</desc></product></catalog>*

* for $product in $abc/catalog/product*
* let $name := $product/name*
* where $product/@dept = "ACC"*
* order by $name*
* return $name*
*};*

xf:Ids()
This post has been answered by Pierluigi Vernetto on Aug 4 2011
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 1 2011
Added on Aug 1 2011
12 comments
1,130 views