query-287b9f53298c8eece65a8180030e89ba

rq turtle/ttl

Propertieschemical formula (P274)

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX bd: <http://www.bigdata.com/rdf#>
PREFIX dcterms: <http://purl.org/dc/terms/>
PREFIX dcterms: <http://purl.org/dc/terms/>
PREFIX wp: <http://vocabularies.wikipathways.org/wp#>

SELECT DISTINCT ?metabolite ?wikidata ?wikidataLabel ?chemFormula WITH {
  SELECT ?metabolite ?wikidata WHERE {
    SERVICE <http://sparql.wikipathways.org/sparql> {
      ?metabolite a wp:Metabolite ;
                  wp:bdbWikidata ?wikidata .
    }
  }
} AS %results WHERE {
  INCLUDE %results
  ?wikidata wdt:P274 ?chemFormula .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}

Query found at