query-8a7e4c72630a6b5755ac8ce58688f13b
Propertiesinstance of (P31)canonization status (P411)feast day (P841)part of (P361)series ordinal (P1545)image (P18)
Use at
- https://query.wikidata.org/sparql
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?item ?itemLabel ?canon ?canonLabel ?diaFestividadLabel
WHERE
{
?item wdt:P31 wd:Q5;
wdt:P411 ?canon;
wdt:P841 ?diaFestividad.
?diaFestividad wdt:P361 ?mes;
p:P361 ?mesStatement.
?mes wdt:P1545 ?numeroMes.
?mesStatement pq:P1545 ?numeroDia.
BIND(MONTH(NOW()) AS ?nowMonth)
BIND(DAY(NOW()) AS ?nowDay)
OPTIONAL { ?item wdt:P18 ?imagen }
FILTER(xsd:integer(?numeroMes) = ?nowMonth)
FILTER(xsd:integer(?numeroDia) = ?nowDay)
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
GROUP BY ?item ?itemLabel ?canon ?canonLabel ?diaFestividadLabel
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v6("?canon"):::projected
v7("?diaFestividad")
v10("?imagen")
v5("?item"):::projected
v8("?mes")
v9("?mesStatement")
v10("?nowDay")
v10("?nowMonth")
v1("?numeroDia")
v3("?numeroMes")
c11(["bd:serviceParam"]):::iri
c2(["wd:Q5"]):::iri
c13(["#91;AUTO_LANGUAGE#93;,en"]):::literal
f0[["http://www.w3.org/2001/XMLSchema#integer(?numeroDia) = ?nowDay"]]
f0 --> v1
f0 --> v10
f1[["http://www.w3.org/2001/XMLSchema#integer(?numeroMes) = ?nowMonth"]]
f1 --> v3
f1 --> v10
v5 --"p:direct/P31"--> c2
v5 --"p:direct/P411"--> v6
v5 --"p:direct/P841"--> v7
v7 --"p:direct/P361"--> v8
v7 --"p:P361"--> v9
v8 --"p:direct/P1545"--> v3
v9 --"p:qualifier/P1545"--> v1
bind2[/"month-from-dateTime(NOW())"/]
bind2 --as--o v10
bind3[/"day-from-dateTime(NOW())"/]
bind3 --as--o v10
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v5 -."p:direct/P18".-> v10
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c11 --"wikibase:language"--> c13
end