Comparing RQL to W3C XQuery
LET $t := document("sirpac-culture-merged.rdf")//description
FOR $artist IN rdf:instance-of-class($t, rdf:predicate-domain($t, "creates"))
LET $artifact := rdf:join-on-property($t, $artist,"creates"),
$museum := rdf:join-on-property($t, $artifact, "exhibited")
{filter($artist | $artist/last_name | $artist/first_name),
filter($museum | $museum/title)}