File: Data.xml File: Query.xqueryfor $d in distinct-values(doc("Data.xml")//employee/@location)let $employees := doc("Data.xml")//employee[@location= $d]order by $dreturn Output: