Project

Profile

Help

How to connect?
Download (466 Bytes) Statistics
| Branch: | Revision:

he / src / use-cases / xmp / addq5.xq @ a31dd97a

1
xquery version "1.0";
2

    
3
(: Additional use case to demonstrate use of global parameters :)
4

    
5

    
6
(: This example is the same as addq4 with the addition of typed variables :)
7

    
8
declare variable $x as xs:string external;
9
declare variable $x-int as xs:int := xs:int($x);
10

    
11
<s>
12
  {  let $open as xs:string := "[",
13
         $close as xs:string := "]"
14
     for $i as xs:integer in $x-int to $x-int + 20 return 
15
        text { $open, string(2*$i), $close }
16
  }
17
</s>
(6-6/38)