gem=Bentheim Bentheim Bentheim xquery version '3.0'; let $context := doc($db:context) let $howmany := 1000 let $lemmata := $context//lemma[geo//gem[matches(.,'^Bentheim$','i')]] return <result lem='{count($lemmata)}' atts='{count($lemmata/following-sibling::att)}' shown='{$howmany}'> { for $i in 1 to min(($howmany, count($lemmata))) let $lem := $lemmata[$i] order by $lem/vorm return <entry> {$lem} {$lem/following-sibling::att} </entry> } </result> Bentheim Bentheim Binedheim mitte 12. D W II a 1, 28 v° Benedhem 1187 D KK 5 a Binethem 1195 Hg B 2 Binnethem 1195 De Benethem 1200 Hg R Benthem 1202 Hg R Benthem 1208 Md 11 Benthem 1213 Hg B 2 Benthem 1217 E D Benthem 1220 U Dom 3379 Benthem 1223 K D 95