This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
ChuQL adds support for Map/Reduce to XQuery mapreduce { input { fn:collection("hdfs://input/") } rr { for $line at $i in $in//line return { key: $i, val: $line } } map { for $word in fn:tokenize($in=>val, " ") return { key: $word, val: 1 } } reduce { { key: $in=>key, val: fn:count($in=>val) } } rw { <word text="{$in=>key}" count="{$in=>val}"/> } output { fn:put($in,"hdfs://output/") } } See ceur-ws.org/Vol-749/paper25.pdf. Seems like a plausible feature that would make XQuery much more useful for Big Data.
This would be better off defined as an XQuery library that accepts function values for the map/reduce methods. As it is a functional language, XQuery expressions can already automatically be split into map/reduce parts and executed in a map/reduce framework.
Assigning to future requirements per Working Group decision (https://lists.w3.org/Archives/Member/w3c-xsl-query/2012Oct/0087.html).