rdf - How to integrate several SPARQL queries -
this query:
prefix pizza: <http://www.data.gov/semantic/data/alpha/1458/dataset-1458.rdf#> prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> prefix dgtwc: <http://data-gov.tw.rpi.edu/2009/data-gov-twc.rdf#> prefix xsd: <http://www.w3.org/2001/xmlschema#> select ?chem <http://ontomatica.com/public/ontologies/dataset-1458.rdf> { ?s dgtwc:uses_property ?chem . filter (regex(str(?chem), '.*sel.*')) . }
produces result
this query:
prefix pizza: <http://www.data.gov/semantic/data/alpha/1458/dataset-1458.rdf#> prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> select ?method <http://ontomatica.com/public/ontologies/dataset-1458.rdf> { ?s rdfs:label ?method filter regex(?method, 'selenium', 'i') }
produces result
for <rdf:description rdf:about="#entry6483">
, how write query produce result?
------------------------------------------------------ | chem | method | selenium | ====================================================== | pizza:selenium | "selenium (mcg/100 g)" | 9 | ------------------------------------------------------
give have entryno "entry6483"
how about
prefix pizza: <http://www.data.gov/semantic/data/alpha/1458/dataset-1458.rdf#> prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> prefix dgtwc: <http://data-gov.tw.rpi.edu/2009/data-gov-twc.rdf#> prefix xsd: <http://www.w3.org/2001/xmlschema#> prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> select ?chem ?method ?selenium <http://ontomatica.com/public/ontologies/dataset-1458.rdf> { pizza:entry6483 ?chem ?selenium . ?chem rdfs:label ?method . filter regex(?method, 'selenium', 'i') }
not sure if looking for!
Comments
Post a Comment