/* l'input dello use case in questo esempio è 'CS1' */ SELECT t.c FROM sparqltable ( SELECT ?b ?c WHERE { ?b rdf:type 'Bambino'. ?b :assegnato ?c. ?c rdf:type 'ClasseDiScol'. } ) t WHERE t.c = 'CS1' GROUP BY t.c HAVING COUNT(t.b) = ( SELECT COUNT(*) FROM sparqltable ( SELECT ?b ?c WHERE { ?b rdf:type 'BambinoNonScol'. ?b :assegnatoScol ?c. ?c rdf:type 'ClasseDiScol'. } ) t WHERE t.c = 'CS1' )