475,243
edits
(create page and add query for FCTs) |
(→Food Composition Tables in WikiFCD: add query for food items with FoodOn id and NALT id) |
||
Line 11: | Line 11: | ||
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } | SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } | ||
} | } | ||
</SPARQL> | |||
== wikiFCD federated query for food items with foodOn id and NALT id== | |||
<SPARQL> | |||
PREFIX wd: <http://www.wikidata.org/entity/> | |||
PREFIX wbt: <https://wikifcd.wikibase.cloud/prop/direct/> | |||
PREFIX wb: <https://wikifcd.wikibase.cloud/entity/> | |||
PREFIX p: <https://wikifcd.wikibase.cloud/prop/> | |||
PREFIX pr: <https://wikifcd.wikibase.cloud/prop/reference/> | |||
PREFIX dct: <http://purl.org/dc/terms/> | |||
SELECT DISTINCT ?item ?itemLabel ?foodon ?nalt WHERE { | |||
?food wbt:P73 ?item. | |||
?item wbt:P1 wb:Q20. | |||
?food wbt:P309 ?foodon. | |||
?item wbt:P61 ?wikidata. | |||
?item rdfs:label ?itemLabel | |||
SERVICE <https://query.wikidata.org/sparql> { | |||
?wikidata wdt:P2004 ?nalt | |||
}} | |||
</SPARQL> | </SPARQL> |