@prefix ex:<https://purl.expasy.org/sparql-examples/neXtProt/> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix schema: <https://schema.org/> .
@prefix sh: <http://www.w3.org/ns/shacl#> .

ex:NXQ_00236 a sh:SPARQLExecutable,
        sh:SPARQLSelectExecutable ;
    rdfs:comment "Proteins with subcellular location gold and list of all these locations"@en ;
    sh:prefixes _:sparql_examples_prefixes ;
    sh:select """PREFIX : <http://nextprot.org/rdf/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>

SELECT DISTINCT ?entry (group_concat(distinct str(?loclab); SEPARATOR = ",") as ?locs) WHERE {
 ?entry :isoform ?iso.
 ?iso :cellularComponent ?locannot .
 ?locannot :term ?locterm .
 ?locterm rdfs:label ?loclab .
 ?locannot :evidence ?locev .
 ?locev :quality :GOLD .
 filter not exists {?locannot :negativeEvidence ?locev .}
}
GROUP BY ?entry""" ;
    schema:keywords "quality",
        "subcellular location",
        "tutorial" ;
    schema:target <https://sparql.nextprot.org/sparql> .

