Question: What is the most specific category that both Lewis Hamilton and Kelly Wallace belong to?

SELECT ?commonClass WHERE { wd:Q9673 wdt:P31 ?commonClass . wd:Q6386328 wdt:P31 ?commonClass . } LIMIT 1

What common type do Lewis Hamilton and Kelly Wallace share?

Which class is an instance of both Lewis Hamilton and Kelly Wallace?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q9673> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q6386328> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most specific shared category between Abu Dhabi and the Las Vegas Strip?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?common WHERE {
  {
    SELECT DISTINCT ?common WHERE {
      wd:Q1519 wdt:P31 ?type .
      ?type wdt:P279 * ?common .
    }
  }
  {
    SELECT DISTINCT ?common WHERE {
      wd:Q745608 wdt:P31 ?type .
      ?type wdt:P279 * ?common .
    }
  }
}
ORDER BY ?common
LIMIT 1

What is the common superclass in the ontology that both Abu Dhabi and the Las Vegas Strip belong to?

What is the highest-level category that includes both Abu Dhabi and the Las Vegas Strip according to Wikidata's classification?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q1519> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q745608> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: Discographies with no performer listed

SELECT ?var1 ?var1Label WHERE { ?var1 wdt:P31 wd:Q273057 . FILTER ( NOT EXISTS { ?var1 wdt:P175 ?performer } ) . ?var1 rdfs:label ?var1Label .}

Which discographies on Wikidata do not have any associated performer?

Show me the names of all discographies that are not linked to any artist or musical performer.

SELECT ?var1 ?var1Label ?var2Label WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q273057> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P175> ?var3 . } FILTER ( ( NOT EXISTS { ?var1 <http://www.wikidata.org/prop/direct/P175> ?var3 . } ) ) . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: What is the most specific category that both Manhattan and Los Angeles belong to?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?commonClass WHERE {
  wd:Q11299 wdt:P31 ?class1 .
  ?class1 wdt:P279 * ?commonClass .
  wd:Q65 wdt:P31 ?commonClass .
}
LIMIT 1

What is the shared classification for Manhattan and Los Angeles in the Wikidata hierarchy?

Find the most specific common class that includes both Manhattan and Los Angeles as instances.

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q11299> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q65> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: Common subclasses of the types of Moon Jae-in and Kennedy Space Center

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?commonClass WHERE {
  wd:Q21001 wdt:P31 ?type1 .
  wd:Q48821 wdt:P31 ?type2 .
  ?type1 wdt:P279 * ?commonClass .
  ?type2 wdt:P279 * ?commonClass .
}
ORDER BY ?commonClass

What classes are both Moon Jae-in and Kennedy Space Center instances of, and what are their shared superclass ancestors?

Show me the common ancestor classes in the hierarchy of the types of Moon Jae-in and Kennedy Space Center.

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q21001> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q48821> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most specific common superclass of the 2008 Brazilian Grand Prix and London?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?ancestor ?label WHERE {
  wd:Q54431 wdt:P31 ?type1 .
  wd:Q84 wdt:P31 ?type2 .
  ?type1 wdt:P279 * ?ancestor .
  ?type2 wdt:P279 * ?ancestor .
  ?ancestor rdfs:label ?label .
  FILTER(LANG(?label) = "en")
}
ORDER BY ASC(?ancestor)
LIMIT 10

What category do both the 2008 Brazilian Grand Prix and London belong to in the Wikidata hierarchy?

Find the most specific shared category in the subclass hierarchy between London and the 2008 Brazilian Grand Prix.

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q54431> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q84> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most specific category that includes both Elon Musk and Al-Qaeda?

SELECT ?ancestor ?label WHERE { wd:Q317521 wdt:P31 ?type1 . wd:Q34490 wdt:P31 ?type2 . ?type1 wdt:P279* ?ancestor . ?type2 wdt:P279* ?ancestor . ?ancestor rdfs:label ?label . FILTER(LANG(?label) = "en") FILTER(CONTAINS(LCASE(?label), "person") && CONTAINS(LCASE(?label), "organization"))}

Which Wikidata class encompasses both humans and organizations, such as Elon Musk and Al-Qaeda?

Find the common superclass of Elon Musk and Al-Qaeda that combines the concepts of person and organization.

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q34490> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q317521> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most specific common category that both Algeria and the United States belong to in the Wikidata taxonomy?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?lca ?label WHERE {
  wd:Q262 wdt:P31 ?type1 .
  wd:Q30 wdt:P31 ?type2 .
  ?type1 wdt:P279 ?mid1 .
  ?type2 wdt:P279 ?mid2 .
  ?mid1 wdt:P279 ?lca .
  ?mid2 wdt:P279 ?lca .
  ?lca rdfs:label ?label .
  FILTER(LANG(?label) = "en")
}
LIMIT 1

Find the least common superclass of Algeria and the United States based on their types in Wikidata.

Which entity is the highest-level shared classification between Algeria and the United States in the subclass hierarchy?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q262> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q30> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What items are linked to Samuel V. Wilson via statements, and what properties are used, along with any qualifiers?

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?item ?statement ?property ( SAMPLE( ?qualifierProperty ) AS ?qualifier ) WHERE {
  ?statement ?statementProperty wd:Q7412817 .
  ?item ?claim ?statement .
  ?property wikibase:claim ?claim ; wikibase:statementProperty ?statementProperty .
  FILTER ( ?property != wd:P31 ) OPTIONAL {
    ?statement ?qualifierProperty ?qualifierValue .
    ?qualifierProperty wikibase:qualifier ?qualifierProperty .
  }
}
GROUP BY ?item ?statement ?property
LIMIT 101

Which entities have statements about Samuel V. Wilson, what properties describe those relationships, and are there any qualifiers attached to those statements?

List all entities connected to Samuel V. Wilson through statements (excluding "instance of"), show the property used in each statement, and indicate any qualifier properties used on those statements.

SELECT ?var1 ?var2 ?var3 ( SAMPLE ( ?var4 ) AS ?var5 ) WHERE { { SELECT DISTINCT ?var1 ?var2 ?var3 WHERE { ?var2 ?var6 <http://www.wikidata.org/entity/Q7412817> . ?var1 ?var7 ?var2 . ?var3 <http://wikiba.se/ontology#statementProperty> ?var6 . ?var3 <http://wikiba.se/ontology#claim> ?var7 . FILTER ( ( ( ?var3 != <http://www.wikidata.org/entity/P31> ) ) ) . } LIMIT 101 } OPTIONAL { ?var2 ?var4 ?var8 . ?var9 <http://wikiba.se/ontology#qualifier> ?var4 . } } GROUP BY ?var1 ?var2 ?var3


Question: What is the most specific shared superclass between humans and countries?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?commonAncestor ( COUNT( ?sub ) AS ?depth ) WHERE {
  wd:Q5 wdt:P279 * ?commonAncestor .
  wd:Q6256 wdt:P279 * ?commonAncestor .
  ?sub wdt:P279 * ?commonAncestor .
}
GROUP BY ?commonAncestor
ORDER BY DESC ( ?depth )
LIMIT 1

What is the highest-level category that both humans and countries belong to through the subclass hierarchy?

Find the most specific common ancestor in the subclass tree for the class of humans and the class of countries.

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q1133513> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q159> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most specific category that both Seoul and New York City belong to?

SELECT ?commonAncestor ?label WHERE { BIND(wd:Q515 AS ?commonAncestor) . wd:Q108178728 wdt:P279* ?commonAncestor . wd:Q1093829 wdt:P279* ?commonAncestor . ?commonAncestor rdfs:label ?label . FILTER(LANG(?label) = "en") }

What is the common superclass in the taxonomy that includes both Seoul and New York City?

Which concept is the least common ancestor of Seoul and New York City in Wikidata’s hierarchy?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q8684> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q60> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most general category that both Earth and Afghanistan belong to?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT DISTINCT ?lca WHERE {
  wd:Q2 wdt:P31 ?t1 .
  wd:Q889 wdt:P31 ?t2 .
  ?t1 wdt:P279 * ?lca .
  ?t2 wdt:P279 * ?lca .
  FILTER ( ?lca = wd:Q35120 )
}

What is the common superclass of all types that Earth and Afghanistan are instances of?

In Wikidata, what is the highest-level concept shared by the planet Earth and the country Afghanistan?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q2> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q889> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most specific category that both Atlanta and Sioux Falls belong to?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?commonType WHERE {
  wd:Q23556 wdt:P31 ?commonType .
  wd:Q131335 wdt:P31 ?commonType .
}
ORDER BY ?commonType
LIMIT 1

Which class do both Atlanta and Sioux Falls share as an instance of?

What type of entity is both Atlanta and Sioux Falls an example of?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q23556> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q131335> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most specific category that both Hungary and North Korea belong to?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?commonClass WHERE {
  wd:Q28 wdt:P31 ?commonClass .
  wd:Q423 wdt:P31 ?commonClass .
  FILTER NOT EXISTS {
    ?otherClass wdt:P279 ?commonClass .
    wd:Q28 wdt:P31 ?otherClass .
    wd:Q423 wdt:P31 ?otherClass .
  }
}

Which class is the lowest common ancestor of Hungary and North Korea in terms of their type?

Find the most specific type shared by Hungary and North Korea.

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q28> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q423> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What are the categories that Hungary and the Interlagos circuit belong to?

SELECT ?entity ?type ?label WHERE { VALUES ?entity { wd:Q28 wd:Q171387 } ?entity wdt:P31 ?type . ?type rdfs:label ?label . FILTER(LANG(?label) = "en") } ORDER BY ?entity

What types of entities are Hungary and Autódromo José Carlos Pace classified as in Wikidata?

Can you list the categories for Hungary and the Interlagos racing track?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q28> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q171387> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most general category that both Hungary and Cincinnati belong to?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?ancestor ?label WHERE {
  wd:Q28 wdt:P31 ?type1 .
  wd:Q43196 wdt:P31 ?type2 .
  BIND(wd:Q35120 AS ?ancestor)
  OPTIONAL {
    ?ancestor rdfs:label ?label .
    FILTER(LANG(?label) = "en")
  }
}

What do Hungary and Cincinnati have in common in terms of their classification in Wikidata?

What is the highest-level class that includes both a country like Hungary and a city like Cincinnati?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q28> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q43196> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most specific category that both Paris and Los Angeles belong to?

SELECT ?commonClass ?label WHERE { wd:Q90 wdt:P31 ?commonClass . wd:Q65 wdt:P31 ?commonClass . ?commonClass rdfs:label ?label . FILTER(LANG(?label) = "en") } ORDER BY ASC(?label) LIMIT 1

Which class is shared by both Paris and Los Angeles, and has the alphabetically first English label?

What term describes both Paris and Los Angeles as globally significant urban centers?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q90> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q65> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: Laotian football players without Spanish Wikipedia descriptions

SELECT DISTINCT ?player WHERE { ?player wdt:P31 wd:Q5 ; wdt:P106 wd:Q937857 ; wdt:P27 wd:Q819 . OPTIONAL { ?player schema:description ?desc . FILTER(LANG(?desc) = "es") } FILTER(!BOUND(?desc)) } LIMIT 300

Who are the human association football players from Laos who do not have a Spanish-language Wikipedia description?

List all Laotian football players who don’t have a Spanish description on Wikipedia.

SELECT DISTINCT ?var1 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . ?var1 <http://www.wikidata.org/prop/direct/P106> <http://www.wikidata.org/entity/Q937857> . ?var1 <http://www.wikidata.org/prop/direct/P21> ?var2 . ?var1 <http://www.wikidata.org/prop/direct/P27> <http://www.wikidata.org/entity/Q819> . OPTIONAL { ?var1 <http://schema.org/description> ?var3 . FILTER ( ( ( LANG ( ?var3 ) = "es" ) ) ) . } FILTER ( ( !( BOUND ( ?var3 ) ) ) ) . } LIMIT 300


Question: What are the geographic coordinates of Capel Peniel and the administrative area it is located in?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?chapelCoordinates ?administrativeAreaCoordinates WHERE {
  wd:Q17739840 wdt:P625 ?chapelCoordinates .
  OPTIONAL {
    wd:Q17739840 wdt:P131 ?administrativeArea .
    ?administrativeArea wdt:P625 ?administrativeAreaCoordinates .
  }
}

Show the exact location of Capel Peniel and the centroid of Tremadog, the town it belongs to.

How do the coordinates of Capel Peniel chapel compare to those of the administrative region it falls under?

SELECT ?var1 ?var2 WHERE { <http://www.wikidata.org/entity/Q17739840> <http://www.wikidata.org/prop/direct/P625> ?var1 . OPTIONAL { <http://www.wikidata.org/entity/Q17739840> <http://www.wikidata.org/prop/direct/P131> ?var3 . ?var3 <http://www.wikidata.org/prop/direct/P625> ?var2 . } }


Question: What is the English name and description of the Great Russian Encyclopedia entry with ID 2334183?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX schema: <http://schema.org/>
SELECT ?item ?itemLabel ?description WHERE {
  ?item wdt:P2924 "2334183" .
  OPTIONAL {
    ?item rdfs:label ?itemLabel .
    FILTER(LANG(?itemLabel) = "en")
  }
  OPTIONAL {
    ?item schema:description ?description .
    FILTER(LANG(?description) = "en")
  }
}

Find the English label and description for the encyclopedia entry identified by the Great Russian Encyclopedia Online ID 2334183.

Show me the English title and summary of the entry in the Great Russian Encyclopedia that has the ID 2334183.

SELECT ?var1 ?var1Label ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2924> "1996973". OPTIONAL { ?var1 <http://schema.org/description> ?var2 . FILTER ( ( ( LANG ( ?var2 ) = "en" ) ) ) . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: Swedish citizens born outside Sweden

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?person ?personLabel ?birthPlace ?birthPlaceLabel WHERE {
  ?person wdt:P31 wd:Q5 .
  ?person wdt:P27 wd:Q34 .
  ?person wdt:P19 ?birthPlace .
  ?birthPlace wdt:P17 ?birthCountry .
  FILTER ( ?birthCountry != wd:Q34 ) .
  ?person rdfs:label ?personLabel .
  ?birthPlace rdfs:label ?birthPlaceLabel .
  FILTER ( LANG( ?personLabel ) = "en" ) .
  FILTER ( LANG( ?birthPlaceLabel ) = "en" ) .
}
LIMIT 100

Which humans are citizens of Sweden but were born in a different country?

List the names of Swedish citizens along with the cities where they were born, excluding those born in Sweden.

SELECT ?var1 ?var2Label ?var3Label WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . ?var1 <http://www.wikidata.org/prop/direct/P19> ?var2 . ?var1 <http://www.wikidata.org/prop/direct/P19> ?var3 . ?var1 <http://www.wikidata.org/prop/direct/P27> <http://www.wikidata.org/entity/Q34> . FILTER ( ( ( ?var3 != ?var2 ) ) ) . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "sv,en". } } LIMIT 100


Question: Who is the person named "René Monzat" in French on Wikidata?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?item WHERE {
  ?item rdfs:label "René Monzat" @fr .
  ?item wdt:P31 wd:Q5 .
}

What Wikidata item corresponds to the French label "René Monzat" and represents a human?

Find the human entity in Wikidata with the French label "René Monzat".

SELECT DISTINCT ?var1 WHERE { ?var1 <http://www.w3.org/2000/01/rdf-schema#label> "Guy Monzat"@fr . ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . }


Question: Alternative names of BNP Paribas in different languages.

SELECT ?alternativeLabel WHERE { wd:Q499707 skos:altLabel ?alternativeLabel .}

What are the different language versions of the name "BNP Paribas"?

Show me all the translated or alternative names for the French bank BNP Paribas.

SELECT ?var1 WHERE { <http://www.wikidata.org/entity/Q499707> <http://www.w3.org/2004/02/skos/core#altLabel> ?var1 . }


Question: What are all the postal codes used in France?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?postalCode WHERE {
  ?place wdt:P17 wd:Q142 ; wdt:P281 ?postalCode .
}

Can you list all the postal codes for cities and towns in France?

Which postal codes are assigned to locations in France?

SELECT ?var1 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q1105640> . }


Question: Museums with labels in 10 or more languages

SELECT ?museum ( COUNT( DISTINCT ?lang ) AS ?langCount ) (SAMPLE(?label) AS ?sampleLabel) WHERE { ?museum wdt:P31 wd:Q33506 . ?museum rdfs:label ?label . BIND( LANG( ?label ) AS ?lang ) . FILTER( LANG( ?label ) != "" ) } GROUP BY ?museum HAVING ( COUNT( DISTINCT ?lang ) >= 10 ) ORDER BY DESC(?langCount) LIMIT 20

Which museums have their names or titles available in at least 10 different languages?

List museums that are available in 10 or more languages, along with the number of languages each is available in.

SELECT ?var1 ( COUNT ( DISTINCT ?var2 ) AS ?var3 ) WHERE { BIND ( LANG ( ?var4Label ) AS ?var2 ). ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q33506> . ?var1 <http://www.w3.org/2000/01/rdf-schema#label> ?var4Label . } GROUP BY ?var1 HAVING ( ( COUNT ( DISTINCT ?var2 ) >= "10"^^<http://www.w3.org/2001/XMLSchema#integer> ) )


Question: What is the Wikidata item for the human named Yves Dumez?

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT DISTINCT ?item WHERE {
  ?item rdfs:label "Yves Dumez" @en .
  ?item wdt:P31 wd:Q5 .
}

Find the person in Wikidata whose name is Yves Dumez.

Which Wikidata entity represents Yves Dumez as a human?

SELECT DISTINCT ?var1 WHERE { ?var1 <http://www.w3.org/2000/01/rdf-schema#label> "Yves Dumez"@fr . ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . }


Question: Observation decks with labels in 10 or more languages

SELECT ?observationDeck ( COUNT( DISTINCT ?lang ) AS ?langCount ) WHERE { ?observationDeck wdt:P31 wd:Q177305 . ?observationDeck rdfs:label ?label . BIND( LANG( ?label ) AS ?lang ) . } GROUP BY ?observationDeck HAVING ( COUNT( DISTINCT ?lang ) >= 10 )

Which observation decks have their names available in at least 10 different languages?

Show me observation decks that are labeled in 10 or more languages.

SELECT ?var1 ( COUNT ( DISTINCT ?var2 ) AS ?var3 ) WHERE { BIND ( LANG ( ?var4Label ) AS ?var2 ). ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q177305> . ?var1 <http://www.w3.org/2000/01/rdf-schema#label> ?var4Label . } GROUP BY ?var1 HAVING ( ( COUNT ( DISTINCT ?var2 ) >= "10"^^<http://www.w3.org/2001/XMLSchema#integer> ) )


Question: What countries or administrative regions is Galilee located in?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?var1 ?var1Label WHERE {
  VALUES ?start {
    wd:Q83241
  }
  {
    ?start wdt:P17 ?var1
  } UNION {
    ?start wdt:P131 ?var1
  } UNION {
    ?start wdt:P131 / wdt:P131 ?var1
  }
  OPTIONAL {
    ?var1 rdfs:label ?var1Label .
    FILTER(LANG(?var1Label) = "en")
  }
}

Show me the administrative divisions and country that contain the region of Galilee.

Is Galilee part of Israel, and if so, which district within Israel does it belong to?

SELECT DISTINCT ?var1 WHERE { BIND ( <http://www.wikidata.org/entity/Q83241> AS ?var2 ). ?var2 ( <http://www.wikidata.org/prop/direct/P30> | <http://www.wikidata.org/prop/direct/P17> | <http://www.wikidata.org/prop/direct/P131> | <http://www.wikidata.org/prop/direct/P376> | <http://www.wikidata.org/prop/direct/P501> )* ?var1 . }


Question: What country and city is Lucky Luyk located in?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?location ?locationLabel WHERE {
  wd:Q2341020 ( wdt:P17 | wdt:P131 ) ?location .
  ?location rdfs:label ?locationLabel .
  FILTER ( LANG( ?locationLabel ) = "en" )
}

Which country and administrative area does the squatter’s house Lucky Luyk belong to?

Show me the country and city associated with Lucky Luyk in Amsterdam.

SELECT DISTINCT ?var1 WHERE { BIND ( <http://www.wikidata.org/entity/Q2341020> AS ?var2 ). ?var2 ( <http://www.wikidata.org/prop/direct/P30> | <http://www.wikidata.org/prop/direct/P17> | <http://www.wikidata.org/prop/direct/P131> | <http://www.wikidata.org/prop/direct/P376> | <http://www.wikidata.org/prop/direct/P501> )* ?var1 . }


Question: Who are the people born in Marrakesh?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?person WHERE {
  ?person wdt:P19 wd:Q101625 .
  ?person wdt:P31 wd:Q5
}

List all humans who have Marrakesh as their place of birth.

Can you find individuals from Marrakesh?

SELECT DISTINCT ?var1 WHERE { ?var1 <http://www.w3.org/2000/01/rdf-schema#label> "marrakchi"@fr . ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . }


Question: Hungarian municipalities in Zala County with population and coordinates

SELECT ?municipality ?population ?coordinates WHERE { ?municipality wdt:P31 wd:Q2590631 ; wdt:P131 ?district . ?district wdt:P131 wd:Q185374 ; wdt:P31 wd:Q1162835 . OPTIONAL { ?municipality wdt:P1082 ?population } . OPTIONAL { ?municipality wdt:P625 ?coordinates } . } ORDER BY ?municipality

Which towns and villages in Zala County, Hungary, have recorded population and geographic coordinates?

List all municipalities in Zala County, Hungary, along with their population and GPS coordinates.

SELECT ?var1 ?var1Label ?var2 ?var3 WHERE { SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q2590631> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q13218690> . } ?var1 <http://www.wikidata.org/prop/direct/P768> <http://www.wikidata.org/entity/Q15725967> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P1082> ?var2 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P625> ?var3 . } } UNION { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q13218690> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q2590631> . } ?var1 <http://www.wikidata.org/prop/direct/P768> <http://www.wikidata.org/entity/Q15725967> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P1082> ?var2 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P625> ?var3 . } } }


Question: Images associated with Stephen Stein, including his gender and employer.

SELECT DISTINCT ?image WHERE { { wd:Q47508780 wdt:P18 ?image . } UNION { wd:Q47508780 wdt:P21 ?gender . ?gender wdt:P18 ?image . } UNION { wd:Q47508780 wdt:P108 ?employer . ?employer wdt:P18 ?image . } }

What images are linked to Stephen Stein, such as those of his gender or workplace?

Show me all images related to Stephen Stein, including those of his gender and employer.

SELECT DISTINCT ?var1 WHERE { { <http://www.wikidata.org/entity/Q47508780> <http://www.wikidata.org/prop/direct/P18> ?var1 . } UNION { <http://www.wikidata.org/entity/Q47508780> !( <http://www.wikidata.org/prop/direct/P1889> ) ?var2 . ?var2 <http://www.wikidata.org/prop/direct/P18> ?var1 . FILTER ( ( ( ?var2 != <http://www.wikidata.org/entity/Q5> ) ) ) . } UNION { ?var3 <http://www.wikidata.org/prop/direct/P50> <http://www.wikidata.org/entity/Q47508780> . { ?var3 <http://www.wikidata.org/prop/direct/P921> [ <http://www.wikidata.org/prop/direct/P18> ?var1 ] . } UNION { ?var4 <http://www.wikidata.org/prop/direct/P50> ?var3 . ?var4 <http://www.wikidata.org/prop/direct/P18> ?var1 . } } }


Question: What are the journals where Uli Fechner has published the most papers, and what are their common abbreviations?

SELECT ?publication ?pubLabel (COUNT(?work) AS ?count)
WHERE {
  ?work wdt:P50 wd:Q47509086 .
  ?work wdt:P1433 ?publication .
  ?publication rdfs:label ?label .
  FILTER(LANG(?label) = "en")
  OPTIONAL { ?publication wdt:P1813 ?shortName }
  BIND(COALESCE(?shortName, ?label) AS ?pubLabel)
}
GROUP BY ?publication ?pubLabel
ORDER BY DESC(?count)

List the publications that have featured Uli Fechner’s work, sorted by number of publications, using abbreviated names where available.

How many publications by Uli Fechner appear in each journal, and what are the English names or abbreviations of those journals?

SELECT ?var1 ?var2Label ( COUNT ( ?var3 ) AS ?var4 ) WHERE { ?var3 <http://www.wikidata.org/prop/direct/P50> <http://www.wikidata.org/entity/Q47509086> . ?var3 <http://www.wikidata.org/prop/direct/P1433> ?var1 . ?var1 <http://www.w3.org/2000/01/rdf-schema#label> ?var5Label . FILTER ( ( ( LANG ( ?var5Label ) = "en" ) ) ) . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P1813> ?var6 . } BIND ( COALESCE ( ?var6 , ?var5Label ) AS ?var2Label ). } GROUP BY ?var1 ?var2Label ORDER BY DESC( ?var4 )


Question: Who were the people affiliated with the Government of Togo, and what roles or occupations did they hold during their tenure, along with the start and end dates?

SELECT DISTINCT ?person ?personLabel ?governmentLabel ?startDate ?endDate ?occupation ?role WHERE { BIND( wd:Q30607454 AS ?government ) . ?person wdt:P31 wd:Q5 . ?person p:P1416 ?statement . ?statement ps:P1416 ?government . OPTIONAL { ?statement pq:P580 ?startDate . } OPTIONAL { ?statement pq:P582 ?endDate . } OPTIONAL { ?statement pq:P106 ?occupationUri . ?occupationUri rdfs:label ?occupation . FILTER ( LANG( ?occupation ) = "en" ) } OPTIONAL { ?statement pq:P2868 ?roleUri . ?roleUri rdfs:label ?role . FILTER ( LANG( ?role ) = "en" ) } ?person rdfs:label ?personLabel . FILTER ( LANG( ?personLabel ) = "en" ) ?government rdfs:label ?governmentLabel . FILTER ( LANG( ?governmentLabel ) = "en" ) } ORDER BY ASC(?startDate) ASC(?occupation) ASC(?role)

List all individuals who had an affiliation with the Government of Togo, including their English names, the time periods of their affiliation, and their roles or occupations in English.

What positions did people hold in the Government of Togo between 1889 and 1914, and when did they serve?

SELECT DISTINCT ?var1 ?var1Label ?var2Label ?var3 ?var4 ?var5 ?var6 WHERE { BIND ( <http://www.wikidata.org/entity/Q30607454> AS ?var2 ). ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . ?var1 <http://www.wikidata.org/prop/P1416> ?var7 . ?var7 <http://www.wikidata.org/prop/statement/P1416> ?var2 . OPTIONAL { ?var7 <http://www.wikidata.org/prop/qualifier/P580> ?var3 . } OPTIONAL { ?var7 <http://www.wikidata.org/prop/qualifier/P582> ?var4 . } OPTIONAL { ?var7 ( <http://www.wikidata.org/prop/qualifier/P106> / <http://www.w3.org/2000/01/rdf-schema#label> ) ?var5 . FILTER ( ( ( LANG ( ?var5 ) = "en" ) ) ) . } OPTIONAL { ?var7 ( <http://www.wikidata.org/prop/qualifier/P2868> / <http://www.w3.org/2000/01/rdf-schema#label> ) ?var6 . FILTER ( ( ( LANG ( ?var6 ) = "en" ) ) ) . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } } ORDER BY ASC( ?var3 )ASC( ?var5 )


Question: Which Wikidata items have Twitter usernames CNBMex, kallmane, McGillLib, unhlibrary, or wikipedia?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?item ?twitterUsername WHERE {
  ?item wdt:P2002 ?twitterUsername .
  VALUES ?twitterUsername {
    "nnschiller" "Mrc_Gthr" "danchagnon" "_BAnQ" "ABQLA" "kallmane" "kgs" "LPanzari" "UMontreal" "BiblioUQAM" "McGillLib" "unhlibrary" "jonhz" "CNBMex" "wikipedia" "WLM_BRASIL" "WLEBRASIL" "wikiedubr"
  }
}

Who or what organizations on Wikidata use the Twitter handles CNBMex, kallmane, McGillLib, unhlibrary, or wikipedia?

List the entities in Wikidata that are associated with the Twitter usernames CNBMex, kallmane, McGillLib, unhlibrary, and wikipedia.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2002> ?var2 . VALUES ( ?var2 ) { ( "nnschiller" ) ( "Mrc_Gthr" ) ( "danchagnon" ) ( "string1" ) ( "_BAnQ" ) ( "string2" ) ( "ABQLA" ) ( "string3" ) ( "kallmane" ) ( "string4" ) ( "kgs" ) ( "LPanzari" ) ( "string5" ) ( "string6" ) ( "UMontreal" ) ( "string7" ) ( "BiblioUQAM" ) ( "McGillLib" ) ( "string8" ) ( "unhlibrary" ) ( "string9" ) ( "string10" ) ( "jonhz" ) ( "CNBMex" ) ( "string11" ) ( "wikipedia" ) ( "WLM_BRASIL" ) ( "WLEBRASIL" ) ( "wikiedubr" ) } }


Question: French historical monuments with Mérimée ID starting with PA and their images.

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT DISTINCT ?monument ?merimeeId ?image WHERE {
  ?monument wdt:P1435 / wdt:P279 * wd:Q916475 .
  ?monument wdt:P380 ?merimeeId .
  FILTER(REGEX(?merimeeId , "^(PA)"))
  OPTIONAL {
    ?monument wdt:P18 ?image .
  }
}
ORDER BY ASC(?merimeeId)
LIMIT 100

Which French historical monuments are listed in the Mérimée database with IDs starting with "PA", and do they have images on Wikimedia Commons?

List up to 100 French monuments designated as historical monuments, sorted by their Mérimée ID, showing their image if available.

SELECT DISTINCT ?var1 ?var2 ?var3 WHERE { ?var1 ( <http://www.wikidata.org/prop/direct/P1435> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q916475> . ?var1 <http://www.wikidata.org/prop/P1435> ?var4 . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P18> ?var3 . } ?var1 <http://www.wikidata.org/prop/direct/P380> ?var2 . FILTER ( ( REGEX ( ?var2 , "^(PA)" ) ) ) . } ORDER BY ASC( ?var5 ) LIMIT 100


Question: What languages are used to label the "instance of" property in Wikidata?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT DISTINCT ?label WHERE {
  wd:P31 rdfs:label ?label .
}
ORDER BY ASC(?label)

In which languages does Wikidata provide labels for the property "instance of"?

Show me all the language-specific labels for the Wikidata property "instance of".

SELECT DISTINCT ?var1 WHERE { OPTIONAL { BIND ( LANG ( ?var2Label ) AS ?var1 ). <http://www.wikidata.org/prop/direct/P31> <http://www.w3.org/2000/01/rdf-schema#label> ?var2Label . } } ORDER BY ASC( ?var1 )


Question: Top 100 subjects of legislation with highest rate of repeal, in English.

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?var1 ?var1Label(COUNT(?var2) AS ?count)(AVG(IF(EXISTS {
  ?var2 wdt:P2568 []
}
, 1 , 0)) AS ?avgRepealed) WHERE {
  ?var2 wdt:P31 / wdt:P279 * wd:Q49371 .
  ?var2 wdt:P921 ?var1 .
  ?var1 rdfs:label ?var1Label .
  FILTER(LANG(?var1Label) = "en")
}
GROUP BY ?var1 ?var1Label
ORDER BY DESC(?avgRepealed)
LIMIT 100

Which topics are most commonly associated with repealed legislation, based on the proportion of repealed laws in Wikidata?

Show me the main subjects of legislation, ranked by how often the associated laws have been repealed, with counts and English labels.

SELECT ?var1 ?var1Label ( COUNT ( ?var2 ) AS ?var3 )( AVG ( ?var4 ) AS ?var5 ) WHERE { BIND ( IF ( EXISTS { ?var2 <http://www.wikidata.org/prop/direct/P2568> ?var3 . } ,"1"^^<http://www.w3.org/2001/XMLSchema#integer> ,"0"^^<http://www.w3.org/2001/XMLSchema#integer> ) AS ?var4 ). ?var2 ( <http://www.wikidata.org/prop/direct/P31> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q49371> . ?var2 <http://www.wikidata.org/prop/direct/P921> ?var1 . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } } GROUP BY ?var1 ?var1Label ORDER BY DESC( ?var5 ) LIMIT 100


Question: What are the Twitter usernames for the United Nations Development Programme?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?item ?twitterUsername WHERE {
  ?item wdt:P2002 ?twitterUsername .
  VALUES ?twitterUsername {
    "undp" "pnud"
  }
}

Which Twitter accounts are associated with the United Nations Development Programme on Wikidata?

Show me the X (Twitter) usernames linked to the United Nations Development Programme in Wikidata, specifically 'undp' and 'pnud'.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2002> ?var2 . VALUES ( ?var2 ) { ( "UNDP4Youth" ) ( "UNDP" ) ( "string1" ) ( "string2" ) } }


Question: Facilities with more than 10 Wikipedia articles, ranked by popularity

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
SELECT ?facility(COUNT(?site) AS ?sitelinks) WHERE {
  ?facility wdt:P31 wd:Q13226383 .
  ?site schema:about ?facility ; schema:isPartOf ?wikipedia .
  FILTER(STRSTARTS(STR(?wikipedia) , "https://"))
}
GROUP BY ?facility
HAVING(COUNT(?site) > 10)
ORDER BY DESC(?sitelinks)
LIMIT 1000

Which facilities have Wikipedia articles in more than 10 languages, and how many languages each has?

List the top 1000 facilities that are covered on Wikipedia in over 10 languages, sorted by the number of language editions.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q13226383> . ?var1 <http://wikiba.se/ontology#sitelinks> ?var2 . FILTER ( ( ( ?var2 > "10"^^<http://www.w3.org/2001/XMLSchema#integer> ) ) ) . } ORDER BY DESC( ?var2 ) LIMIT 1000


Question: Publications with "safe" in the title and their authors, limited to English-language entries.

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?publication ?instanceType ?instanceLabel ?publicationLabel ?author ?authorLabel WHERE {
  ?publication wdt:P31 ?instanceType .
  FILTER(?instanceType = wd:Q732577 || ?instanceType = wd:Q83790)
  ?instanceType rdfs:label ?instanceLabel .
  FILTER(LANG(?instanceLabel) = "en")
  ?publication rdfs:label ?publicationLabel .
  FILTER(LANG(?publicationLabel) = "en")
  ?publication wdt:P50 ?author .
  ?author rdfs:label ?authorLabel .
  FILTER(LANG(?authorLabel) = "en")
  FILTER(REGEX(?publicationLabel , "safe" , "i"))
}
LIMIT 10

Which English-language publications contain the word "safe" in their title, and who are their authors?

Show me the authors of publications (not textbooks) whose titles include the word "safe", with all labels in English.

SELECT DISTINCT * WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> ?var2 . FILTER ( ( ( ?var2 = <http://www.wikidata.org/entity/Q732577> ) || ( ?var2 = <http://www.wikidata.org/entity/Q83790> ) ) ) . ?var2 <http://www.w3.org/2000/01/rdf-schema#label> ?var3Label . FILTER ( ( ( LANG ( ?var3Label ) = "en" ) ) ) . ?var1 <http://www.w3.org/2000/01/rdf-schema#label> ?var4Label . FILTER ( ( ( LANG ( ?var4Label ) = "en" ) ) ) . ?var1 <http://www.wikidata.org/prop/direct/P50> ?var5 . ?var5 <http://www.w3.org/2000/01/rdf-schema#label> ?var6Label . FILTER ( ( ( LANG ( ?var6Label ) = "en" ) ) ) . FILTER ( ( REGEX ( ?var4Label , "safe", "i" ) ) ) . } OFFSET 0 LIMIT 10


Question: Who has the Twitter username "fdouetteau"?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?person ?twitterUsername WHERE {
  ?person wdt:P2002 ?twitterUsername .
  VALUES ?twitterUsername {
    "fdouetteau"
  }
}

Which Wikidata item corresponds to the Twitter handle fdouetteau?

Find the person associated with the Twitter/X username "fdouetteau".

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2002> ?var2 . VALUES ( ?var2 ) { ( "fdouetteau" ) } }


Question: What are the top 10 railway stations with the most Wikipedia language editions?

SELECT ?station ?count WHERE { ?station wdt:P31 wd:Q55488 . { SELECT ?station (COUNT(?page) AS ?count) WHERE { ?page schema:about ?station . ?page schema:isPartOf ?wiki . } GROUP BY ?station HAVING (?count > 1) } } ORDER BY DESC(?count) LIMIT 1000

Which railway stations are covered in more than one Wikipedia language, ranked by how many languages they appear in?

Show me railway stations that have articles in at least two Wikipedia languages, sorted by the number of languages, with the most popular first.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q55488> . ?var1 <http://wikiba.se/ontology#sitelinks> ?var2 . FILTER ( ( ( ?var2 > "1"^^<http://www.w3.org/2001/XMLSchema#integer> ) ) ) . } ORDER BY DESC( ?var2 ) LIMIT 1000


Question: What infobox template is most specifically associated with camera operators and has a Russian Wikipedia page?

SELECT ?template ?topic (COUNT(?general) AS ?generalizations) WHERE { ?template wdt:P31 wd:Q19887878 . ?template wdt:P1423 ?topic . wd:Q1208175 wdt:P279* ?topic . ?general wdt:P279* ?topic . ?wikipediaPage schema:about ?template ; schema:isPartOf <https://ru.wikipedia.org/> . } GROUP BY ?template ?topic ORDER BY ASC(?generalizations) LIMIT 1

Which Wikipedia infobox template, linked to a topic that camera operators belong to, is used most frequently on Russian Wikipedia pages?

Find the infobox template for people in the filmmaking profession that has a Russian version and is the most specific to camera operators.

SELECT DISTINCT ?var1 WHERE { { SELECT DISTINCT ?var1 ?var2 ?var3 ?var4 ( COUNT ( ?var5 ) AS ?var6 ) WHERE { { SELECT DISTINCT ?var1 ?var2 ( COUNT ( ?var7 ) AS ?var4 ) WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q19887878> . ?var1 <http://www.wikidata.org/prop/direct/P1423> ?var2 . <http://www.wikidata.org/entity/Q1208175> ( <http://www.wikidata.org/prop/direct/P31> | <http://www.wikidata.org/prop/direct/P106> ) ?var8 . ?var8 <http://www.wikidata.org/prop/direct/P279> * ?var7 . ?var7 <http://www.wikidata.org/prop/direct/P279> * ?var2 . } GROUP BY ?var1 ?var2 } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P279> * ?var5 . ?var5 <http://www.wikidata.org/prop/direct/P279> * ?var3 . } } GROUP BY ?var1 ?var2 ?var3 ?var4 } FILTER ( ( EXISTS { ?var9 <http://schema.org/about> ?var1 . ?var9 <http://schema.org/isPartOf> <https://ru.wikipedia.org/> . } ) ) . } ORDER BY ASC( ?var4 ) DESC( ?var6 ) LIMIT 1


Question: What is the most frequently used infobox template on the Russian Wikipedia?

SELECT ?template (COUNT(?page) AS ?usageCount)
WHERE {
  ?template wdt:P31 wd:Q19887878 .
  ?page schema:isPartOf <https://ru.wikipedia.org/> .
  ?page schema:about ?item .
  ?item wdt:P31 ?topic .
  ?template wdt:P1423 ?topic .
}
GROUP BY ?template
ORDER BY DESC(?usageCount)
LIMIT 1

Which infobox template appears the most times on Russian Wikipedia pages?

How many times is the "Infobox person" template used on Russian Wikipedia?

SELECT DISTINCT ?var1 WHERE { { SELECT DISTINCT ?var1 ?var2 ?var3 ?var4 ( COUNT ( ?var5 ) AS ?var6 ) WHERE { { SELECT DISTINCT ?var1 ?var2 ( COUNT ( ?var7 ) AS ?var4 ) WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q19887878> . ?var1 <http://www.wikidata.org/prop/direct/P1423> ?var2 . <http://www.wikidata.org/entity/Q4435038> ( <http://www.wikidata.org/prop/direct/P31> | <http://www.wikidata.org/prop/direct/P106> ) ?var8 . ?var8 <http://www.wikidata.org/prop/direct/P279> * ?var7 . ?var7 <http://www.wikidata.org/prop/direct/P279> * ?var2 . } GROUP BY ?var1 ?var2 } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P279> * ?var5 . ?var5 <http://www.wikidata.org/prop/direct/P279> * ?var3 . } } GROUP BY ?var1 ?var2 ?var3 ?var4 } FILTER ( ( EXISTS { ?var9 <http://schema.org/about> ?var1 . ?var9 <http://schema.org/isPartOf> <https://ru.wikipedia.org/> . } ) ) . } ORDER BY ASC( ?var4 ) DESC( ?var6 ) LIMIT 1


Question: What are the birth and death dates of Franziska Donner?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?label ?birthDate ?deathDate WHERE {
  wd:Q113840 rdfs:label ?label .
  OPTIONAL {
    wd:Q113840 wdt:P569 ?birthDate .
  }
  OPTIONAL {
    wd:Q113840 wdt:P570 ?deathDate .
  }
  FILTER(LANG(?label) = "en")
}

Can you tell me when Franziska Donner was born and when she died?

Provide the life span of Franziska Donner, including her birth and death dates.

SELECT ?var1Label ?var2 ?var3 ?var4 WHERE { BIND ( <http://www.wikidata.org/entity/Q113840> AS ?var1 ). ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P569> ?var3 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P570> ?var4 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: What are the birth and death dates of Kuroda Naoyasu?

SELECT ?label ?birthDate ?deathDate WHERE { wd:Q11678645 rdfs:label ?label . FILTER(LANG(?label) = "ja") OPTIONAL { wd:Q11678645 wdt:P569 ?birthDate . } OPTIONAL { wd:Q11678645 wdt:P570 ?deathDate . } }

Can you tell me the Japanese name, birth date, and death date of the person with Wikidata ID Q11678645?

Who was the Japanese samurai born in 1819 and died in 1876?

SELECT ?var1Label ?var2 ?var3 ?var4 WHERE { BIND ( <http://www.wikidata.org/entity/Q11678645> AS ?var1 ). ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P569> ?var3 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P570> ?var4 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: What are the birth and death dates of Tony Street?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?label ?birthDate ?deathDate WHERE {
  BIND(wd:Q2442849 AS ?person)
  ?person wdt:P31 wd:Q5 .
  ?person rdfs:label ?label .
  FILTER(LANG(?label) = "en")
  OPTIONAL {
    ?person wdt:P569 ?birthDate .
  }
  OPTIONAL {
    ?person wdt:P570 ?deathDate .
  }
}

Can you tell me when Tony Street was born and when he died?

Provide the full name, birth date, and death date of the Australian politician Tony Street.

SELECT ?var1Label ?var2 ?var3 ?var4 WHERE { BIND ( <http://www.wikidata.org/entity/Q2442849> AS ?var1 ). ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P569> ?var3 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P570> ?var4 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: Which breweries have the most Wikipedia language editions, and how many are there?

SELECT ?brewery (COUNT(?page) AS ?sitelinkCount) WHERE { ?brewery wdt:P31 wd:Q131734 . ?page schema:about ?brewery . FILTER(REGEX(STR(?page), "^https://[^/]+\\.wikipedia\\.org")) } GROUP BY ?brewery ORDER BY DESC(?sitelinkCount) LIMIT 1000

List the top 1000 breweries based on how many Wikipedia articles exist about them.

Find breweries that are mentioned on Wikipedia in multiple languages, ordered by the number of languages.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q131734> . ?var1 <http://wikiba.se/ontology#sitelinks> ?var2 . FILTER ( ( ( ?var2 > "0"^^<http://www.w3.org/2001/XMLSchema#integer> ) ) ) . } ORDER BY DESC( ?var2 ) LIMIT 1000


Question: How many Batman video games have English Wikipedia articles?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
SELECT(COUNT(DISTINCT ?game) AS ?count) WHERE {
  ?game wdt:P31 wd:Q7889 .
  ?game rdfs:label ?label .
  ?wikipediaPage schema:about ?game .
  FILTER(STRSTARTS(STR(?wikipediaPage) , "https://en.wikipedia.org/wiki/"))
  FILTER(REGEX(?label , ".*batman.*" , "i"))
}

How many video games featuring Batman are linked to English Wikipedia pages?

Count the number of Batman-themed video games that have corresponding English Wikipedia articles.

SELECT( COUNT ( DISTINCT ?var1 ) AS ?var2 ) WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q7889> . ?var1 <http://www.w3.org/2000/01/rdf-schema#label> ?var1Label . ?var3 <http://schema.org/about> ?var1 . FILTER ( ( ( SUBSTR ( STR ( ?var3 ) ,"1"^^<http://www.w3.org/2001/XMLSchema#integer> ,"25"^^<http://www.w3.org/2001/XMLSchema#integer> ) = "string1" ) ) ) . FILTER ( ( REGEX ( ?var1Label , ".*batman.*", "i" ) ) ) . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } } LIMIT 20


Question: People with an account on XVideos

SELECT ?person ?personLabel WHERE { ?person wdt:P553 wd:Q3700050 . ?person rdfs:label ?personLabel . FILTER(LANG(?personLabel) = "en") } LIMIT 100

Who has an account on the website XVideos?

List the individuals who have an account on XVideos.

SELECT ?var1 ?var1Label WHERE { SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } ?var1 <http://www.wikidata.org/prop/direct/P553> <http://www.wikidata.org/entity/Q3700050> . } LIMIT 100


Question: Wikidata items with Chinese labels and descriptions that have a Wikimedia Commons category.

SELECT ?item ?itemLabel ?itemDescription WHERE { ?item wdt:P373 ?category . ?item rdfs:label ?itemLabel . ?item schema:description ?itemDescription . FILTER(LANG(?itemLabel) = "zh-hans") FILTER(LANG(?itemDescription) = "zh-hans") } LIMIT 100

Which Wikidata items have both a Chinese label and a Chinese description, and are associated with a Wikimedia Commons category?

Please list the Chinese labels and descriptions of Wikidata items that are linked to a Wikimedia Commons category.

SELECT ?var1 ?var2Label ?var3 WHERE { <http://www.bigdata.com/queryHints#Query> <http://www.bigdata.com/queryHints#optimizer> "None". { SELECT DISTINCT ?var1 WHERE { ?var4 <http://www.wikidata.org/prop/direct/P373> ?var1 . } LIMIT 100 } ?var1 <http://www.w3.org/2000/01/rdf-schema#label> ?var2Label . ?var1 <http://schema.org/description> ?var3 . FILTER ( ( ( LANG ( ?var2Label ) = "zh-hans" ) ) ) . FILTER ( ( ( LANG ( ?var3 ) = "zh-hans" ) ) ) . } LIMIT 100


Question: Short names of para rowing event classes at the World Rowing Championships

SELECT ?event ?eventLabel ?classAbbreviation WHERE { ?event wdt:P31 wd:Q21246076 ; wdt:P361 [ wdt:P31 wd:Q1413606 ] ; wdt:P2094 [ wdt:P1813 ?classAbbreviation ; wdt:P641 wd:Q1575010 ] . ?event rdfs:label ?eventLabel . FILTER(LANG(?eventLabel) = "en") }

What are the abbreviated class names for para rowing events in the World Rowing Championships?

List the para rowing events from the World Rowing Championships and their official competition class abbreviations.

SELECT ?var1 ?var1Label ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q21246076> ; <http://www.wikidata.org/prop/direct/P361> [ <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q1413606> ] ; <http://www.wikidata.org/prop/direct/P2094> [ <http://www.wikidata.org/prop/direct/P1813> ?var2 ; <http://www.wikidata.org/prop/direct/P641> <http://www.wikidata.org/entity/Q1575010> ] . MINUS { ?var1 <http://www.wikidata.org/prop/direct/P3157> [] . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "de,de". } }


Question: Where was Abraham Rademaker born?

SELECT ?birthPlace WHERE { wd:Q2534646 wdt:P19 ?birthPlace .}

What is the place of birth of the Dutch painter Abraham Rademaker?

Tell me the birthplace of Abraham Rademaker, the 17th-century Dutch artist.

SELECT ?var1 WHERE { <http://www.wikidata.org/entity/Q2534646> <http://www.wikidata.org/prop/direct/P19> ?var1 . }


Question: Birthplace of Isaac da Costa

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?birthplace WHERE {
  wd:Q1673766 wdt:P19 ?birthplace .
}

What is the city where the Dutch poet and theologian Isaac da Costa was born?

SELECT ?var1 WHERE { <http://www.wikidata.org/entity/Q1673766> <http://www.wikidata.org/prop/direct/P19> ?var1 . }


Question: Organizations founded after January 29, 2018, with their English labels and inception dates.

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?item ?inceptionDate ?itemLabel WHERE {
  ?item wdt:P31 wd:Q43229 ; wdt:P571 ?inceptionDate .
  FILTER ( ?inceptionDate > "2018-01-29" ^^ xsd:date ) OPTIONAL {
    ?item rdfs:label ?itemLabel .
    FILTER ( LANG( ?itemLabel ) = "en" )
  }
}
ORDER BY ?inceptionDate

Which organizations were established after January 29, 2018, and when were they founded?

List all organizations that started after January 29, 2018, including their English names and founding dates, sorted by date.

SELECT( ( NOW ( ) - "2018-01-29"^^<http://www.w3.org/2001/XMLSchema#dateTime> ) AS ?var1 ) WHERE { }


Question: Wikipedia articles about Montréal-Nord

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
SELECT ?page WHERE {
  ?page schema:about wd:Q1714436 .
}

Which Wikipedia pages discuss Montréal-Nord?

Show me all the Wikipedia links related to Montréal-Nord.

SELECT * WHERE { ?var1 ?var2 <http://www.wikidata.org/entity/Q1714436> . }


Question: Wikimedia categories with main topic taxon

PREFIX ps: <http://www.wikidata.org/prop/statement/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?category ?categoryLabel WHERE {
  ?category p:P301 ?statement .
  ?statement ps:P301 wd:Q16521 .
  ?category rdfs:label ?categoryLabel .
  FILTER ( LANG( ?categoryLabel ) = "en" )
}
LIMIT 10

What are the English Wikipedia categories whose main topic is taxon?

List the English-labeled Wikipedia categories that are about taxonomic units.

SELECT ?var1 ?var2 ( SAMPLE ( ?var3 ) AS ?var4 ) WHERE { { SELECT DISTINCT ?var1 ?var2 WHERE { ?var2 <http://www.wikidata.org/prop/statement/P301> <http://www.wikidata.org/entity/Q16521> . ?var1 <http://www.wikidata.org/prop/P301> ?var2 . } LIMIT 101 } OPTIONAL { ?var2 ?var3 ?var5 . ?var6 <http://wikiba.se/ontology#qualifier> ?var3 . } } GROUP BY ?var1 ?var2


Question: What are some examples of consumer electronics?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?item ?itemLabel WHERE {
  ?item wdt:P31 wd:Q581105 .
  ?item rdfs:label ?itemLabel .
  FILTER(LANG(?itemLabel) = "en")
}

Which devices are classified as consumer electronics on Wikidata?

List the English names of products that are instances of consumer electronics.

SELECT ?var1 ?var1Label WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q581105> . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } }


Question: What are the volumes of the Brockhaus and Efron Encyclopedic Dictionary?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?volume ?volumeLabel WHERE {
  ?volume wdt:P361 wd:Q602358 .
  ?volume rdfs:label ?volumeLabel .
  FILTER ( LANG( ?volumeLabel ) = "en" )
}
LIMIT 1000

Which volumes make up the Brockhaus and Efron Encyclopedic Dictionary?

List the English-labeled volumes that are part of the Brockhaus and Efron Encyclopedic Dictionary.

SELECT ?var1 ?var1Label WHERE { SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "uk,en". } ?var1 <http://www.wikidata.org/prop/direct/P361> <http://www.wikidata.org/entity/Q602358> . } LIMIT 1000


Question: Japanese Wikipedia articles with the Good Article badge

PREFIX schema: <http://schema.org/>
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?article WHERE {
  ?article schema:isPartOf <https://ja.wikipedia.org/> ; wikibase:badge wd:Q17437798 .
}

Which articles on the Japanese Wikipedia have been designated as Good Articles?

List all the URLs of Japanese Wikipedia pages that carry the Good Article badge.

SELECT ?var1 WHERE { ?var1 <http://schema.org/isPartOf> <https://ja.wikipedia.org/> ; <http://wikiba.se/ontology#badge> <http://www.wikidata.org/entity/Q17437798> . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } }


Question: List artworks from the Groeningemuseum with their inventory numbers, creators, and clickable URLs.

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?artwork ?inventoryNumber ?instance ?instanceLabel ?creator ?creatorLabel ?workPID ?url WHERE {
  ?artwork wdt:P195 wd:Q1948674 .
  OPTIONAL {
    ?artwork wdt:P217 ?inventoryNumber .
  }
  OPTIONAL {
    ?artwork wdt:P31 ?instance .
  }
  OPTIONAL {
    ?artwork wdt:P170 ?creator .
  }
  OPTIONAL {
    ?artwork wdt:P2282 ?workPID .
  }
  wd:P2282 wdt:P1630 ?formatterUrl .
  BIND(REPLACE(?formatterUrl , "\\$1" , ?workPID) AS ?url)
  OPTIONAL {
    ?instance rdfs:label ?instanceLabel .
    FILTER(LANG(?instanceLabel) = "en")
  }
  OPTIONAL {
    ?creator rdfs:label ?creatorLabel .
    FILTER(LANG(?creatorLabel) = "en")
  }
}
LIMIT 10

What are the artworks in the Groeningemuseum collection, and how can I access them via their persistent identifiers using the museum’s URL format?

Show me the artworks from the Groeningemuseum, including their creators, types (e.g., painting), inventory numbers, and direct URLs generated from their P2282 IDs using the museum’s URL template.

SELECT ?var1 ?var2 ?var3 ?var4 ?var5 ?var5Label ?var6 ?var6Label ?var7 ?var7Label ?var8 ?var9 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P195> <http://www.wikidata.org/entity/Q1948674> . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "nl". } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P217> ?var2 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P18> ?var3 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P571> ?var4 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P31> ?var5 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P195> ?var6 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P170> ?var7 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P2282> ?var8 . } BIND ( IRI ( REPLACE ( ?var8 , "^(.+)$", ?var10 ) ) AS ?var9 ). ?var11 <http://wikiba.se/ontology#directClaim> <http://www.wikidata.org/prop/direct/P2282> . ?var11 <http://wikiba.se/ontology#propertyType> <http://wikiba.se/ontology#ExternalId> . ?var11 <http://www.wikidata.org/prop/direct/P1630> ?var10 . }


Question: People who directed and acted in films, ranked by number of films.

SELECT ?person ?personLabel (COUNT(?film) AS ?count) WHERE { ?film wdt:P31 wd:Q11424 . ?film wdt:P57 ?person . ?film wdt:P161 ?person . ?person rdfs:label ?personLabel . FILTER(LANG(?personLabel) = "en") } GROUP BY ?person ?personLabel ORDER BY DESC(?count)

Who are the filmmakers that have both directed and acted in the most films?

List the directors who also starred in their own films, sorted by how many such films they made.

SELECT ?var1 ?var1Label ( COUNT ( ?var2 ) AS ?var3 ) WHERE { ?var2 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q11424> . ?var2 <http://www.wikidata.org/prop/direct/P57> ?var1 . ?var2 <http://www.wikidata.org/prop/direct/P161> ?var1 . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "zh-cn,en". } } GROUP BY ?var1 ?var1Label ORDER BY DESC( ?var3 )


Question: French-labeled humans named Blondel

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT DISTINCT ?item WHERE {
  ?item rdfs:label "Blondel" @fr .
  ?item wdt:P31 wd:Q5
}

Who are the humans in Wikidata with the French label 'Blondel'?

List all humans whose French label is 'Blondel'.

SELECT DISTINCT ?var1 WHERE { ?var1 <http://www.w3.org/2000/01/rdf-schema#label> "blondel"@fr . ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . }


Question: Predecessor of Manuela Schwesig as Federal Minister of Family Affairs

SELECT ?replaced WHERE { wd:Q72845 wdt:P39 ?position . ?statement ps:P39 ?position ; pq:P1366 ?replaced . FILTER (?position = wd:Q30543531) }

Who did Manuela Schwesig replace when she became Federal Minister of Family Affairs, Senior Citizens, Women and Youth?

Find the person who held the position of Federal Minister of Family Affairs, Senior Citizens, Women and Youth before Manuela Schwesig.

SELECT ?var1 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P39> [ ( <http://www.wikidata.org/prop/direct/P31> */ <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q248352> ; <http://www.wikidata.org/prop/direct/P1365> <http://www.wikidata.org/entity/Q72845> ] . }


Question: Who is the person named "Agnès Jaoui" in French, and is known to be a human?

SELECT DISTINCT ?item WHERE { ?item rdfs:label "Agnès Jaoui"@fr . ?item wdt:P31 wd:Q5 .}

Find the Wikidata item for the French-labeled person "Agnès Jaoui".

What human entity has the French label "Agnès Jaoui"?

SELECT DISTINCT ?var1 WHERE { ?var1 <http://www.w3.org/2000/01/rdf-schema#label> "Agnès Woog"@fr . ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . }


Question: Musical groups starting with "Ab" and their English genres.

SELECT ?group ?genreLabel ?groupLabel WHERE { ?group wdt:P31 wd:Q215380 . ?group wdt:P136 ?genre . ?group rdfs:label ?groupLabel . ?genre rdfs:label ?genreLabel . FILTER (LANG(?groupLabel) = "en") . FILTER (LANG(?genreLabel) = "en") . FILTER (STRSTARTS(?groupLabel, "Ab")) . } LIMIT 100

What are the English-language names of musical groups that start with "Ab", and what genres are they associated with?

List all musical groups whose names begin with "Ab" in English, along with their English genre labels.

SELECT ?var1 ?var2Label ?var1Label WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q215380> . ?var1 <http://www.wikidata.org/prop/direct/P136> ?var2 ; <http://www.w3.org/2000/01/rdf-schema#label> ?var3Label . FILTER ( ( ( LANG ( ?var3Label ) = "en" ) ) ) . FILTER ( ( STRSTARTS ( ?var3Label , "Ab" ) ) ) . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } } LIMIT 100


Question: Who are the people who died at Siriraj Hospital in Bangkok?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?person ?personLabel ?deathPlace WHERE {
  ?person wdt:P20 wd:Q4385323 .
  ?person wdt:P31 wd:Q5 .
  ?person rdfs:label ?personLabel .
  wd:Q4385323 rdfs:label ?deathPlace .
  FILTER(LANG(?personLabel) = "en")
  FILTER(LANG(?deathPlace) = "en")
}

List the names of notable individuals who passed away at Siriraj Hospital, along with the hospital's name.

Which humans died at Siriraj Hospital, and what is the name of the hospital where they died?

SELECT ?var1 ?var1Label ?var2 WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q4385323> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Reverse"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "6"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#maxVisited> "4"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P20> . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P20> ?var2 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "th". } }


Question: Image of the person with SNAC ARK ID w61t33tj

SELECT ?image WHERE { ?person wdt:P3430 "w61t33tj" . OPTIONAL { ?person wdt:P18 ?image . } }

What is the image of Balthus as identified by the SNAC ARK ID w61t33tj?

Show me the Wikimedia Commons image associated with the SNAC ARK ID w61t33tj.

SELECT ?var1 WHERE { ?var2 <http://www.wikidata.org/prop/direct/P3430> "w61t33tj". OPTIONAL { ?var2 <http://www.wikidata.org/prop/direct/P18> ?var1 . } }


Question: What are the taxonomic details of the fish species *Osteobrama bhimensis*?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?speciesLabel ?parentTaxonLabel ?taxonRankLabel ?gbifId ?colId WHERE {
  wd:Q1102413 wdt:P171 ?parentTaxon ; wdt:P105 ?taxonRank ; wdt:P846 ?gbifId ; wdt:P10585 ?colId .
  wd:Q1102413 rdfs:label ?speciesLabel .
  ?parentTaxon rdfs:label ?parentTaxonLabel .
  ?taxonRank rdfs:label ?taxonRankLabel .
  FILTER ( LANG( ?speciesLabel ) = "en" ) FILTER ( LANG( ?parentTaxonLabel ) = "en" ) FILTER ( LANG( ?taxonRankLabel ) = "en" )
}

Can you tell me the parent taxon, rank, GBIF ID, and Catalogue of Life ID for *Osteobrama bhimensis*?

Provide the English label, parent taxon, taxon rank, GBIF ID, and Catalogue of Life ID for the species Osteobrama bhimensis.

SELECT ?var1 ?var1Label ?var2 ?var2Label ?var3 ?var3Label ?var4 ?var4Label WHERE { ?var3 <http://wikiba.se/ontology#claim> ?var5 . ?var3 <http://wikiba.se/ontology#statementProperty> ?var6 . ?var3 <http://wikiba.se/ontology#qualifier> ?var7 . ?var3 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://wikiba.se/ontology#Property> . ?var4 <http://wikiba.se/ontology#claim> ?var8 . ?var4 <http://wikiba.se/ontology#qualifier> ?var9 . ?var4 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://wikiba.se/ontology#Property> . ?var1 ?var5 ?var10 . ?var10 ?var6 ?var2 . ?var10 ?var9 <http://www.wikidata.org/entity/Q1102413> . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: Scholarly articles citing "Pachygyria, joint contractures, and facial abnormalities"

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?citingArticle ?citingArticleLabel ?citationProperty WHERE {
  ?citingArticle ?statementProperty wd:Q41634729 .
  ?citationProperty wikibase:directClaim ?statementProperty .
  ?citingArticle rdfs:label ?citingArticleLabel .
  FILTER ( LANG( ?citingArticleLabel ) = "en" )
}
LIMIT 100

Which academic papers cite the article on pachygyria, joint contractures, and facial abnormalities?

List the titles of articles that reference the 1989 paper on pachygyria, joint contractures, and facial abnormalities, and confirm they use the "cited in" property.

SELECT ?var1 ?var1Label ?var2 ?var2Label WHERE { ?var1 ?var3 <http://www.wikidata.org/entity/Q41634729> . ?var2 <http://wikiba.se/ontology#directClaim> ?var3 . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } } LIMIT 100


Question: What are all the administrative regions and countries that the building "Conjunt d'habitatges plurifamiliars de la Caixa de Pensions" is located in, up to the continent level?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?location WHERE {
  {
    wd:Q28152415 wdt:P131 + ?location
  } UNION {
    wd:Q28152415 wdt:P131 + ?admin .
    ?admin wdt:P17 ?location
  } UNION {
    wd:Q28152415 wdt:P131 + ?admin .
    ?admin wdt:P17 ?country .
    ?country wdt:P30 ?location
  }
}

Show the geographic hierarchy of the residential building in Girona, including its city, province, region, country, and continent.

Which countries and continents include the residential building Conjunt d'habitatges plurifamiliars de la Caixa de Pensions, and what administrative divisions connect it to them?

SELECT DISTINCT ?var1 WHERE { BIND ( <http://www.wikidata.org/entity/Q28152415> AS ?var2 ). ?var2 ( <http://www.wikidata.org/prop/direct/P30> | <http://www.wikidata.org/prop/direct/P17> | <http://www.wikidata.org/prop/direct/P131> | <http://www.wikidata.org/prop/direct/P376> | <http://www.wikidata.org/prop/direct/P501> )* ?var1 . }


Question: Main subjects of works by Katherine Thornton, ordered by frequency.

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?count ?subjectLabel WHERE {
  {
    SELECT ?subject(COUNT(?work) AS ?count) WHERE {
      ?work wdt:P50 wd:Q41533116 .
      ?work wdt:P921 ?subject .
    }
    GROUP BY ?subject
    ORDER BY DESC(?count)
  }
  ?subject rdfs:label ?subjectLabel .
  FILTER(LANG(?subjectLabel) = "en")
}

What are the most common topics of the works authored by Katherine Thornton, and how many works are there for each topic?

Show me the English labels of the main subjects of Katherine Thornton’s works, along with how many works each subject appears in, sorted from most to least frequent.

SELECT ?var1 ?var2Label ?var3Label WHERE { { SELECT ?var4 ( COUNT ( ?var5 ) AS ?var1 ) WHERE { ?var5 <http://www.wikidata.org/prop/direct/P50> <http://www.wikidata.org/entity/Q41533116> . ?var5 <http://www.wikidata.org/prop/direct/P921> ?var4 . } GROUP BY ?var4 ORDER BY DESC( ?var1 ) } BIND ( SUBSTR ( ?var6Label ,"1"^^<http://www.w3.org/2001/XMLSchema#integer> ,"60"^^<http://www.w3.org/2001/XMLSchema#integer> ) AS ?var3Label ). ?var5 <http://www.wikidata.org/prop/direct/P50> <http://www.wikidata.org/entity/Q41533116> . ?var5 <http://www.wikidata.org/prop/direct/P921> ?var4 . ?var4 <http://www.w3.org/2000/01/rdf-schema#label> ?var2Label . FILTER ( ( ( LANG ( ?var2Label ) = "en" ) ) ) . ?var5 <http://www.w3.org/2000/01/rdf-schema#label> ?var6Label . FILTER ( ( ( LANG ( ?var6Label ) = "en" ) ) ) . }


Question: Who is the French-speaking human named Lucien Lièvre?

SELECT DISTINCT ?item WHERE { ?item rdfs:label "Lucien Lièvre"@fr . ?item wdt:P31 wd:Q5 . }

Find the Wikidata item for the person named Lucien Lièvre in French.

What is the identifier for Lucien Lièvre, the French painter, in Wikidata?

SELECT DISTINCT ?var1 WHERE { ?var1 <http://www.w3.org/2000/01/rdf-schema#label> "Luc Lièvre"@fr . ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . }


Question: How many papers from the 22nd International Joint Conference on Artificial Intelligence were cited exactly 2 or 3 times, and how many papers have each of those citation counts?

SELECT ?citationCount (COUNT(?paper) AS ?paperCount)
WHERE {
  {
    SELECT ?paper (COUNT(?citingWork) AS ?citationCount)
    WHERE {
      ?paper wdt:P1433 wd:Q46476302 .  # paper published in IJCAI 2011 proceedings
      OPTIONAL {
        ?citingWork wdt:P2860 ?paper .  # ?citingWork cites ?paper
      }
    }
    GROUP BY ?paper
  }
}
GROUP BY ?citationCount
ORDER BY DESC(?citationCount)

Citation frequency distribution of papers published in IJCAI 2011 proceedings

Show me how many papers in the IJCAI 2011 proceedings have 2 citations and how many have 3 citations.

SELECT ?var1 ( COUNT ( ?var2 ) AS ?var3 ) WHERE { { SELECT ?var2 ( COUNT ( ?var4 ) AS ?var1 ) WHERE { ?var2 <http://www.wikidata.org/prop/direct/P1433> <http://www.wikidata.org/entity/Q46476302> . OPTIONAL { ?var4 <http://www.wikidata.org/prop/direct/P2860> ?var2 . } } GROUP BY ?var2 } } GROUP BY ?var1 ORDER BY DESC( ?var1 )


Question: What creative works have genres related to animals, such as beast fable or animal art?

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?item ?itemLabel WHERE {
  ?item wdt:P136 ?genre .
  VALUES ?genre {
    wd:Q2516435 wd:Q16875712 wd:Q2302151
  }
  .
  ?item rdfs:label ?itemLabel .
  FILTER ( LANG( ?itemLabel ) = "en" )
}

Can you list books or artworks that are classified under animal-themed genres like beast fable?

Which literary works or paintings use animals as a central theme in their genre classification?

SELECT ?var1 WHERE { ?var1 ( <http://www.wikidata.org/prop/direct/P136> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q729> . }


Question: All Wikimedia categories and biological subclasses related to the animal kingdom.

SELECT ?categoryOrTaxon WHERE { ?categoryOrTaxon (wdt:P301 / wdt:P279*) wd:Q729 . }

What are all the taxonomic groups and categories that are classified under the animal kingdom in Wikidata?

List all categories and their subcategories that have the animal kingdom as their main topic or are subclasses of such categories.

SELECT ?var1 WHERE { ?var1 ( <http://www.wikidata.org/prop/direct/P301> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q729> . }


Question: French communes with "Lyon" in their name

SELECT ?commune ?communeLabel WHERE { ?commune wdt:P31 wd:Q484170 ; rdfs:label ?communeLabel . FILTER (REGEX(?communeLabel, "Lyon", "i")) }

Which communes in France have "Lyon" in their name?

List all communes in France whose names include the word Lyon.

SELECT ?var1 ?var1Label WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q484170> ; <http://www.w3.org/2000/01/rdf-schema#label> ?var1Label . FILTER ( ( REGEX ( ?var1Label , "string1" ) ) ) . }


Question: Image of William Wirt with SNAC ARK ID w6sb45bg

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?image WHERE {
  ?item wdt:P3430 "w6sb45bg" .
  OPTIONAL {
    ?item wdt:P18 ?image .
  }
}

What is the image associated with William Wirt's SNAC ARK ID w6sb45bg?

Show me the Wikimedia Commons image of the person identified by SNAC ARK ID w6sb45bg.

SELECT ?var1 WHERE { ?var2 <http://www.wikidata.org/prop/direct/P3430> "w6sb45bg". OPTIONAL { ?var2 <http://www.wikidata.org/prop/direct/P18> ?var1 . } }


Question: Who are the federal ministers of Germany?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?person WHERE {
  ?person wdt:P39 [ ( wdt:P31 | wdt:P279 ) wd:Q248352 ] .
}

Which people have held a position that is either a federal minister or a subclass of federal minister in Germany?

List all individuals who have served as federal ministers or in roles that are subclasses of federal minister in Germany.

SELECT ?var1 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P39> [ ( <http://www.wikidata.org/prop/direct/P31> | <http://www.wikidata.org/prop/direct/P279> ) <http://www.wikidata.org/entity/Q248352> ] . }


Question: Finnish municipalities with the number of national built heritage sites located in each, sorted alphabetically.

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?municipality ?municipalityLabel(SUBSTR(STR(?municipality) , 32) AS ?qId)(COUNT(?heritageItem) AS ?heritageCount) WHERE {
  {
    ?heritageItem wdt:P361 ?heritageComplex .
    ?heritageComplex wdt:P4009 ?rkyId .
  } UNION {
    ?heritageItem wdt:P4009 ?rkyId .
  }
  ?heritageItem wdt:P131 ?municipality .
  ?municipality rdfs:label ?municipalityLabel .
  FILTER(LANG(?municipalityLabel) = "en")
}
GROUP BY ?municipality ?municipalityLabel
ORDER BY ASC(?municipalityLabel)

Which Finnish municipalities have the most national heritage sites registered in the RKY database, and how many are there in each?

List all municipalities (in English) that contain items listed in Finland’s RKY national built heritage database, including the count of such items per municipality, ordered by municipality name.

SELECT ?var1 ?var1Label ( SUBSTR ( STR ( ?var1 ) ,"32"^^<http://www.w3.org/2001/XMLSchema#integer> ,"250"^^<http://www.w3.org/2001/XMLSchema#integer> ) AS ?var2 )( COUNT ( ?var1 ) AS ?var3 ) WHERE { { ?var4 <http://www.wikidata.org/prop/direct/P361> ?var5 . ?var5 <http://www.wikidata.org/prop/direct/P4009> ?var6 . } UNION { ?var4 <http://www.wikidata.org/prop/direct/P4009> ?var6 . } ?var4 <http://www.wikidata.org/prop/direct/P131> ?var1 . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "fi". } } GROUP BY ?var1 ?var1Label ORDER BY ASC( ?var1Label )


Question: What is the most general category that both Ramallah and American Airlines belong to?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?commonAncestor WHERE {
  VALUES ?commonAncestor {
    wd:Q35120
  }
  wd:Q158119 wdt:P31 ?c1 .
  ?c1 wdt:P279 * ?commonAncestor .
  wd:Q32396 wdt:P31 ?c2 .
  ?c2 wdt:P279 * ?commonAncestor .
}

Is there any shared classification between the city of Ramallah and American Airlines?

What is the highest-level common class in Wikidata for Ramallah and American Airlines?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q158119> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q32396> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: What is the most specific category that includes both humans and organizations in Wikidata?

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?ancestor ?ancestorLabel WHERE {
  VALUES ?ancestor {
    wd:Q106559804
  }
  ?ancestor rdfs:label ?ancestorLabel .
  FILTER ( LANG( ?ancestorLabel ) = "en" )
}

What is the common superclass of a person and a company in Wikidata's ontology?

Which Wikidata class groups together both individuals and organizations?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q11192> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q2283> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: Who are the businesspeople born in Croydon?

SELECT ?person ?personLabel WHERE { ?person wdt:P19 wd:Q2213391 ; wdt:P106 wd:Q43845 . ?person rdfs:label ?personLabel . FILTER(LANG(?personLabel) = "en") } ORDER BY ?personLabel

List people from Croydon whose occupation is businessperson.

Which notable individuals from Croydon are involved in business?

SELECT ?var1 ( ( ?var2 + ?var3 ) AS ?var4 ) WHERE { SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q2006045> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var2 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } SERVICE <http://www.bigdata.com/rdf/gas#service> { <http://www.bigdata.com/rdf/gas#program> <http://www.bigdata.com/rdf/gas#gasClass> "com.bigdata.rdf.graph.analytics.SSSP"; <http://www.bigdata.com/rdf/gas#in> <http://www.wikidata.org/entity/Q2213391> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Forward"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var3 ; <http://www.bigdata.com/rdf/gas#maxIterations> "10"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } } ORDER BY ASC( ?var4 ) LIMIT 1


Question: Cities in Märkischer Kreis with GND IDs

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?item ?itemLabel ?gnd WHERE {
  ?item wdt:P131 wd:Q5937 .
  ?item wdt:P31 wd:Q515 .
  ?item wdt:P227 ?gnd .
  ?item rdfs:label ?itemLabel .
  FILTER(LANG(?itemLabel) = 'en')
}

Which cities in the Märkischer Kreis district in Germany have a GND ID?

List the cities located in Märkischer Kreis that are identified by a German National Library ID.

SELECT DISTINCT ?var1 ?var1Label WHERE { ?var1 <http://www.wikidata.org/prop/direct/P131> <http://www.wikidata.org/entity/Q5937> . ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q262166> . ?var1 <http://www.wikidata.org/prop/direct/P227> ?var2 . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "de". } }


Question: What is the English title and description of the film with LdiF ID 48501?

SELECT ?film ?filmLabel ?description WHERE { ?film wdt:P3107 "48501" . OPTIONAL { ?film schema:description ?description . FILTER (LANG(?description) = "en") } ?film rdfs:label ?filmLabel . FILTER (LANG(?filmLabel) = "en") }

What is the English name and plot summary of the movie identified by the LdiF ID 48501?

Please provide the English title and a brief description of the film that has the LdiF ID 48501.

SELECT ?var1 ?var1Label ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P3107> "48501". OPTIONAL { ?var1 <http://schema.org/description> ?var2 . FILTER ( ( ( LANG ( ?var2 ) = "en" ) ) ) . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }