Sign in
apache
/
vxquery
/
43e6daad781a16c230210812f6e6ffeb7aa55936
/
.
/
vxquery-xtest
/
src
/
test
/
resources
/
Queries
/
XQuery
/
Aggregate
/
Partition-2
/
sum.xq
blob: ce0c562b709c25b243dca00f1367c1181608dc3a [
file
] [
log
] [
blame
]
(: XQuery Aggregate Query :)
(: Find the total precipitation. :)
fn:sum
(
let
$collection
:=
"ghcnd_half_1|ghcnd_half_2"
for
$r
in
collection
(
$collection
)/dataCollection/
data
where
$r
/dataType
eq
"PRCP"
return
$r
/value
)