query-f0d06238999755ff413818cfb8c79abe

rq turtle/ttl

TODO TagishsimonTagishsimon! Thanks for Creating these queries

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?item ?itemLabel ?property ?propertyLabel ?type  ?sproperty ?spropertyLabel ?value ?valueLabel WHERE
{
   {
  SELECT ?statement ?type ?property ?sproperty ?value WHERE 
  {
    ?statement ?predicate wd:Q5885.


    {?property wikibase:statementProperty ?predicate. 
    BIND("statement" as ?type) }
    UNION
    {?property wikibase:qualifier ?predicate. 
    filter not exists {wd:P407 wikibase:qualifier ?predicate. } 
    BIND("qualifier" as ?type)
    ?statement ?predicate3 ?value .
    ?sproperty wikibase:statementProperty ?predicate3 .
    }
    UNION
    {?property wikibase:reference ?predicate. 
    filter not exists {wd:P407 wikibase:reference ?predicate. } 
    BIND("reference" as ?type) 
    ?statement ?predicate3 ?value .
    ?sproperty wikibase:statementProperty ?predicate3 .
    }
  } 
} 
  ?item ?predicate2 ?statement .
  ?property2 wikibase:claim ?predicate2. 
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en,ta". } 
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v8("?item"):::projected v2("?predicate") v9("?predicate2") v5("?predicate3") v3("?property"):::projected v10("?property2") v7("?sproperty"):::projected v1("?statement") v8("?type"):::projected v6("?value"):::projected c10(["#91;AUTO_LANGUAGE#93;,en,ta"]):::literal c8(["bd:serviceParam"]):::iri c1(["wd:Q5885"]):::iri c3(["wd:P407"]):::iri v1 -->v2--> c1 subgraph union0[" Union "] subgraph union0l[" "] style union0l fill:#abf,stroke-dasharray: 3 3; subgraph union1[" Union "] subgraph union1l[" "] style union1l fill:#abf,stroke-dasharray: 3 3; f0[["not "]] subgraph f0e0["Exists Clause"] e0c1 --"wikibase:reference"--> e0v1 e0v1("?predicate"):::projected e0c1(["wd:P407"]):::iri end f0--EXISTS--> f0e0 f0 --> c3 f0 --> c5 f0 --> v2 c3 --"wikibase:reference"--> v2 v3 --"wikibase:reference"--> v2 bind1[/"'reference'"/] bind1 --as--o v8 v1 -->v5--> v6 v7 --"wikibase:statementProperty"--> v5 end subgraph union1r[" "] style union1r fill:#abf,stroke-dasharray: 3 3; f2[["not "]] subgraph f2e1["Exists Clause"] e1c1 --"wikibase:qualifier"--> e1v1 e1v1("?predicate"):::projected e1c1(["wd:P407"]):::iri end f2--EXISTS--> f2e1 f2 --> c3 f2 --> c4 f2 --> v2 c3 --"wikibase:qualifier"--> v2 v3 --"wikibase:qualifier"--> v2 bind3[/"'qualifier'"/] bind3 --as--o v8 v1 -->v5--> v6 v7 --"wikibase:statementProperty"--> v5 end union1r <== or ==> union1l end end subgraph union0r[" "] style union0r fill:#abf,stroke-dasharray: 3 3; v3 --"wikibase:statementProperty"--> v2 bind4[/"'statement'"/] bind4 --as--o v8 end union0r <== or ==> union0l end v8 -->v9--> v1 v10 --"wikibase:claim"--> v9 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c8 --"wikibase:language"--> c10 end