|
>Home>Learn XQuery> XQuery Tips and Tricks>Dynamic Text
Print
Can I use dynamic text as the name of a result node?
Yes, you can use computed constructors (http://www.w3.org/TR/xquery/#id-computedConstructors):
let $r := "some-dynamic-value"
return
element {$r} {'something'}
to return...
<some-dynamic-value>something</some-dynamic-value>
Next Question!
How can I return the result of multiple expressions?
|