Project

Profile

Help

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

he / src / use-cases / r / q1.xq @ a31dd97a

1
<result>
2
  {
3
  let $current-date := xs:date('1999-01-31') return
4
    for $i in doc("items.xml")//item_tuple
5
    where $i/start_date <= $current-date
6
      and $i/end_date >= $current-date 
7
      and contains($i/description, "Bicycle")
8
    order by $i/itemno
9
    return
10
        <item_tuple>
11
            { $i/itemno }
12
            { $i/description }
13
        </item_tuple>
14
  }
15
</result>
(5-5/42)