Question: Which Wikidata entities have Twitter usernames BASEsearch, clmbirn, c_riesen, EvoMRI, katja_mat, KGoepfrich, MsPhelps, nichtich, wikidata, or ZENODO_ORG?

SELECT ?entity ?username WHERE { ?entity wdt:P2002 ?username . VALUES ?username { "BASEsearch" "clmbirn" "c_riesen" "EvoMRI" "katja_mat" "KGoepfrich" "MsPhelps" "nichtich" "wikidata" "ZENODO_ORG" } }

Who are the people or organizations on Wikidata with the Twitter handles BASEsearch, clmbirn, c_riesen, EvoMRI, katja_mat, KGoepfrich, MsPhelps, nichtich, wikidata, and ZENODO_ORG?

List the Wikidata items and their corresponding Twitter usernames for the following handles: BASEsearch, clmbirn, c_riesen, EvoMRI, katja_mat, KGoepfrich, MsPhelps, nichtich, wikidata, and ZENODO_ORG.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2002> ?var2 . VALUES ( ?var2 ) { ( "string1" ) ( "c_riesen" ) ( "string2" ) ( "ZENODO_ORG" ) ( "string3" ) ( "BASEsearch" ) ( "OK_Maps" ) ( "string4" ) ( "MsPhelps" ) ( "string5" ) ( "string6" ) ( "string7" ) ( "clmbirn" ) ( "SIBehrens" ) ( "string8" ) ( "wikidata" ) ( "katja_mat" ) ( "KGoepfrich" ) ( "iansample" ) ( "string9" ) ( "string10" ) ( "nichtich" ) ( "EvoMRI" ) } }


Question: Image of Tadeusz Borowski (SNAC ARK ID w61w3c0s)

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

What is the image associated with the SNAC ARK ID w61w3c0s?

Show me the Wikimedia Commons image for the person with SNAC ARK ID w61w3c0s.

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


Question: Public services in France and their official websites, sorted by type and name.

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 ?service ?typeLabel ?serviceLabel ?website WHERE {
  ?service ( wdt:P31 / wdt:P279 * ) wd:Q161837 ; wdt:P17 wd:Q142 .
  ?service wdt:P31 ?type .
  OPTIONAL {
    ?service wdt:P856 ?website .
  }
  ?type rdfs:label ?typeLabel .
  ?service rdfs:label ?serviceLabel .
  FILTER ( LANG( ?typeLabel ) = "en" ) FILTER ( LANG( ?serviceLabel ) = "en" )
}
ORDER BY ASC ( ?typeLabel ) ASC ( ?serviceLabel )

What are the public services in France, what types of services are they, and do they have official websites?

List all public services in France, including their English labels, their classification types (e.g., association, brand, syndicate), and their official websites, sorted alphabetically by type and service name.

SELECT ?var1 ?var2Label ?var1Label ?var3 WHERE { ?var1 ( <http://www.wikidata.org/prop/direct/P31> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q161837> ; <http://www.wikidata.org/prop/direct/P17> <http://www.wikidata.org/entity/Q142> . ?var1 <http://www.wikidata.org/prop/direct/P31> ?var2 . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P856> ?var3 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "fr,en". } } ORDER BY ASC( ?var2Label )ASC( ?var1Label )


Question: What are the parent categories of machine learning up to five levels up in the classification hierarchy?

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 ?ancestorLabel WHERE {
  {
    wd:Q2539 wdt:P279 ?ancestor .
  } UNION {
    wd:Q2539 wdt:P279 ?int1 .
    ?int1 wdt:P279 ?ancestor .
  } UNION {
    wd:Q2539 wdt:P279 ?int1 .
    ?int1 wdt:P279 ?int2 .
    ?int2 wdt:P279 ?ancestor .
  } UNION {
    wd:Q2539 wdt:P279 ?int1 .
    ?int1 wdt:P279 ?int2 .
    ?int2 wdt:P279 ?int3 .
    ?int3 wdt:P279 ?ancestor .
  } UNION {
    wd:Q2539 wdt:P279 ?int1 .
    ?int1 wdt:P279 ?int2 .
    ?int2 wdt:P279 ?int3 .
    ?int3 wdt:P279 ?int4 .
    ?int4 wdt:P279 ?ancestor .
  }
  ?ancestor rdfs:label ?ancestorLabel .
  FILTER ( LANG( ?ancestorLabel ) = "en" ) FILTER ( ?ancestor != wd:Q2539 )
}
ORDER BY ?ancestor

Show me all the academic disciplines that machine learning is a subclass of, going up to five generations of broader categories.

List the broader fields of study that include machine learning, with labels in English, within five levels of abstraction.

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/Q2539> ; <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> "5"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#maxVisited> "100"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P279> ?var2 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: What are all the subfields of pattern recognition in computer science, and what are their immediate parent categories?

SELECT ?subclass ?subclassLabel ?directParent WHERE { ?subclass wdt:P279* wd:Q378859 . ?subclass rdfs:label ?subclassLabel . FILTER(LANG(?subclassLabel) = "en") OPTIONAL { ?subclass wdt:P279 ?directParent . } }

List all techniques related to pattern recognition, including their direct parent classes, in English.

Show me the hierarchy of pattern recognition subtypes, showing each subtype and what class it directly belongs to.

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


Question: What are the federal governments of the world?

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 ?government ?governmentLabel WHERE {
  ?government wdt:P31 wd:Q1006644 .
  ?government rdfs:label ?governmentLabel .
  FILTER(LANG(?governmentLabel) = "en")
}

List the names of all countries or entities that have a federal government.

Which governments are classified as federal governments, like that of Germany?

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


Question: Which French academic rectorates have Twitter usernames "acbesancon" or "acrennes"?

SELECT ?institution ?twitterUsername WHERE { ?institution wdt:P2002 ?twitterUsername . VALUES ?twitterUsername { "acbesancon" "acrennes" } }

What institutions on Wikidata have the Twitter usernames "acbesancon" and "acrennes"?

Show me the institutions associated with the Twitter handles acbesancon and acrennes.

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


Question: List all Canadian ministries that are instances of the Cabinet of Canada.

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

What are the names of all Canadian ministries that belong to the Cabinet of Canada?

Show me the English labels of all Canadian ministries that are direct instances of the Cabinet of Canada.

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


Question: Products and their manufacturers, sorted by product name.

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?product ?productLabel ?manufacturerLabel WHERE {
  ?product wdt:P176 ?manufacturer .
  ?product rdfs:label ?productLabel .
  ?manufacturer rdfs:label ?manufacturerLabel .
  FILTER ( LANG( ?productLabel ) = "en" ) FILTER ( LANG( ?manufacturerLabel ) = "en" )
}
ORDER BY ASC ( ?productLabel )

What are the products and who manufactured them, listed in alphabetical order by product name?

Please list all products along with their manufacturers in English, sorted alphabetically by the product name.

SELECT ?var1 ?var1Label ?var2Label WHERE { ?var1 <http://www.wikidata.org/prop/direct/P176> ?var3 . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } } ORDER BY ASC( ?var1Label )


Question: Items in the Louvre Museum collection with English labels

SELECT DISTINCT ?item ?itemLabel WHERE { ?item wdt:P195 wd:Q19675 . ?item rdfs:label ?itemLabel . FILTER(LANG(?itemLabel) = "en") }

What are the English names of artworks held by the Louvre Museum?

List the English labels of all items in the Louvre Museum’s collection.

SELECT DISTINCT ?var1 ?var1Label ( CONCAT ( "string1", STR ( ?var2 ) ) AS ?var3 ) WHERE { ?var1 <http://www.wikidata.org/prop/direct/P195> <http://www.wikidata.org/entity/Q19675> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P1212> ?var2 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "fr". } }


Question: Rembrandt paintings in the Rijksmuseum or Louvre Museum with images and titles.

SELECT ?painting ?paintingLabel ?image ?museum WHERE { ?painting wdt:P31 wd:Q3305213 ; wdt:P170 wd:Q5598 ; (wdt:P195 / wdt:P361*) ?museum . FILTER (?museum IN (wd:Q190804, wd:Q19675)) OPTIONAL { ?painting wdt:P18 ?image } ?painting wdt:P1476 ?paintingLabel . FILTER(LANGMATCHES(LANG(?paintingLabel), "en")) }

What are the English titles and images of Rembrandt’s paintings held in the Rijksmuseum or the Louvre?

List Rembrandt’s paintings in the Rijksmuseum and Louvre Museum, including their titles and images.

SELECT ?var1 ?var1Label ?var2 ?var3 ?var4 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q3305213> ; <http://www.wikidata.org/prop/direct/P170> <http://www.wikidata.org/entity/Q5598> ; ( <http://www.wikidata.org/prop/direct/P195> / <http://www.wikidata.org/prop/direct/P361> *) ?var4 . FILTER ( ( ( ?var4 = <http://www.wikidata.org/entity/Q190804> ) || ( ?var4 = <http://www.wikidata.org/entity/Q19675> ) ) ) . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P18> ?var3 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: List all buildings in Groningen.

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?building WHERE {
  ?building wdt:P31 wd:Q13691604 ; wdt:P131 wd:Q9899 .
}

What are the buildings located in Groningen?

Show me the buildings in Groningen that are classified as buildings in Wikidata.

SELECT ?var1 WHERE { <https://adamlink.nl/geo/building/leprozensteeg-8/773> <https://www.wikidata.org/wiki/Property:P31> <http://www.wikidata.org/entity/Q13691604> ; <https://www.wikidata.org/wiki/Property:P131> <http://www.wikidata.org/entity/Q9899> . }


Question: What properties are used for IBM 709, what are their labels, how many values do they have, and what are those values labeled in English?

SELECT ?property (SAMPLE(?propLabel) AS ?propertyLabel) (COUNT(?value) AS ?valueCount) (GROUP_CONCAT(?valueLabel; SEPARATOR=", ") AS ?valueLabelsConcat) WHERE { wd:Q548219 ?property ?value . ?value rdfs:label ?valueLabel . FILTER(LANG(?valueLabel) = "en") . ?propertyItem wikibase:directClaim ?property . ?propertyItem rdfs:label ?propLabel . FILTER(LANG(?propLabel) = "en") } GROUP BY ?property

For the IBM 709 computer, what are the properties assigned to it, their English labels, the count of their values, and the English names of those values?

List all properties of IBM 709 with their English labels, the number of values each has, and the English labels of those values.

SELECT ?var1 ( SAMPLE ( ?var2 ) AS ?var2 )( COUNT ( ?var3 ) AS ?var4 )( GROUP_CONCAT ( ?var5 ; SEPARATOR = ", " ) AS ?var5 ) WHERE { <http://www.wikidata.org/entity/Q548219> ?var1 ?var3 . ?var3 <http://www.w3.org/2000/01/rdf-schema#label> ?var5 . FILTER ( ( ( LANG ( ?var5 ) = "en" ) ) ) . ?var6 <http://wikiba.se/ontology#directClaim> ?var1 . ?var6 <http://www.w3.org/2000/01/rdf-schema#label> ?var2 . FILTER ( ( ( LANG ( ?var2 ) = "en" ) ) ) . } GROUP BY ?var1


Question: How many items associated with the Principality of Albania have an image on Wikimedia Commons?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT(COUNT(DISTINCT ?item) AS ?count) WHERE {
  {
    ?item wdt:P17 wd:Q187035 .
  } UNION {
    ?item wdt:P131 wd:Q187035 .
  }
  ?item wdt:P18 ?image .
}

How many things linked to the Principality of Albania (either directly or through administrative subdivisions) are illustrated with an image?

Can you tell me how many historical entities from the Principality of Albania have a publicly available image?

SELECT( COUNT ( DISTINCT ?var1 ) AS ?var2 ) WHERE { { { ?var1 <http://www.wikidata.org/prop/direct/P17> <http://www.wikidata.org/entity/Q187035> . } UNION { ?var1 <http://www.wikidata.org/prop/direct/P131> <http://www.wikidata.org/entity/Q187035> . } } ?var1 <http://www.wikidata.org/prop/direct/P18> ?var3 . }


Question: Paintings by Rembrandt in the Rijksmuseum or Louvre with images.

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?painting ?paintingLabel ?image ?museum WHERE {
  ?painting wdt:P31 wd:Q3305213 ; wdt:P170 wd:Q5598 ; ( wdt:P195 / wdt:P361 * ) ?museum .
  FILTER ( ?museum IN ( wd:Q190804 , wd:Q19675 ) ) OPTIONAL {
    ?painting wdt:P18 ?image .
  }
  ?painting rdfs:label ?paintingLabel .
  FILTER ( LANG( ?paintingLabel ) = "en" )
}

Which paintings created by Rembrandt are held in the Rijksmuseum or the Louvre, and what are their images?

Show me Rembrandt’s paintings that are in either the Rijksmuseum or the Louvre, along with their English titles and available images.

SELECT DISTINCT ?var1 ?var1Label ?var2 ?var3 ?var4 ?var5 ?var6 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q3305213> ; <http://www.wikidata.org/prop/direct/P170> <http://www.wikidata.org/entity/Q5598> ; ( <http://www.wikidata.org/prop/direct/P195> / <http://www.wikidata.org/prop/direct/P361> *) ?var4 . FILTER ( ( ( ?var4 = <http://www.wikidata.org/entity/Q190804> ) || ( ?var4 = <http://www.wikidata.org/entity/Q19675> ) ) ) . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P18> ?var3 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "fr". } }


Question: Facebook-related companies and their alternative names and industries

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/>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
SELECT DISTINCT ?label ?altLabel ?industryLabel WHERE {
  {
    ?company wdt:P31 wd:Q4830453 .
  } UNION {
    ?company wdt:P31 wd:Q7248095 .
  } UNION {
    ?company wdt:P31 wd:Q693737 .
  }
  ?company rdfs:label ?label .
  FILTER ( CONTAINS( LCASE( ?label ) , "facebook" ) ) OPTIONAL {
    ?company skos:altLabel ?altLabel .
  }
  OPTIONAL {
    ?company wdt:P452 ?industry .
    ?industry rdfs:label ?industryLabel .
  }
}

What are the different language labels, alternative names, and industries for companies related to Facebook?

List all entities classified as businesses, professional services networks, or Aktiengesellschafts that are related to Facebook, along with their alternative labels and industry classifications.

SELECT DISTINCT ?var1Label ?var2 ?var3Label WHERE { { ?var4 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q4830453> . } UNION { ?var4 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q7248095> . } UNION { ?var4 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q693737> . } ?var4 <http://www.w3.org/2000/01/rdf-schema#label> ?var1Label . FILTER ( ( CONTAINS ( ?var1Label , "Facebook" ) ) ) . OPTIONAL { ?var4 <http://www.w3.org/2004/02/skos/core#altLabel> ?var2 . } OPTIONAL { ?var4 <http://www.wikidata.org/prop/direct/P452> ?var3 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: What countries are listed as operating areas for entities with Facebook usernames?

SELECT DISTINCT ?country ?countryLabel WHERE { ?item p:P2013 ?stmt . ?stmt pq:P2541 ?country . ?country rdfs:label ?countryLabel . }

Which countries are associated with Facebook account profiles through their operating area qualifier?

Can you list the countries where organizations or individuals with Facebook profiles operate?

SELECT DISTINCT ?var1 ?var1Label WHERE { ?var2 ( <http://www.wikidata.org/prop/P2013> / <http://www.wikidata.org/prop/qualifier/P2541> ) ?var1 . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } }


Question: Entities with LinkedIn URLs in their described at URL property.

SELECT ?entity ?linkedinUrl WHERE { ?entity wdt:P973 ?linkedinUrl . FILTER (CONTAINS(STR(?linkedinUrl), "linkedin")) } ORDER BY ?entity

Which entities on Wikidata have LinkedIn profiles listed as their described URL?

Show me the entities and their LinkedIn URLs for all items that have a LinkedIn profile linked via the "described at URL" property.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P973> ?var2 . FILTER ( ( REGEX ( STR ( ?var2 ) , "linkedin" ) ) ) . }


Question: List of ministries of agriculture with their official English names.

SELECT ?var1 ?var1Label WHERE { ?var1 wdt:P31 wd:Q1364302 . ?var1 rdfs:label ?var1Label . FILTER(LANG(?var1Label) = "en") } LIMIT 21

What are the English names of government ministries responsible for agriculture?

Show me up to 21 ministries of agriculture and their official names in English.

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


Question: What companies are part of the DAX index, who owns them, and what percentage of each company is owned by those entities?

PREFIX ps: <http://www.wikidata.org/prop/statement/>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?componentLabel ?ownerLabel ?proportion WHERE {
  wd:Q155718 wdt:P527 ?component .
  ?component p:P127 ?ownershipStatement .
  ?ownershipStatement ps:P127 ?owner ; pq:P1107 ?proportion .
  ?component rdfs:label ?componentLabel .
  ?owner rdfs:label ?ownerLabel .
  FILTER(LANG(?componentLabel) = "en")
  FILTER(LANG(?ownerLabel) = "en")
}
ORDER BY ASC(?ownerLabel)

List the owners of DAX constituent companies along with their ownership shares, sorted alphabetically by owner name.

Which institutions or individuals hold stakes in DAX-listed firms, and how large are those stakes?

SELECT ?var1Label ?var2Label ?var3 WHERE { <http://www.wikidata.org/entity/Q155718> <http://www.wikidata.org/prop/direct/P527> ?var1 . ?var1 <http://www.wikidata.org/prop/P127> ?var4 . ?var4 <http://www.wikidata.org/prop/statement/P127> ?var2 ; <http://www.wikidata.org/prop/qualifier/P1107> ?var3 . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "de". } } ORDER BY ASC( ?var2Label )


Question: What is the English label of Novartis, its type (e.g., pharmaceutical company), and its logo image?

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?companyLabel ?typeLabel ?image WHERE {
  wd:Q507154 rdfs:label ?companyLabel .
  FILTER ( LANG( ?companyLabel ) = "en" ) .
  wd:Q507154 wdt:P31 ?type .
  ?type rdfs:label ?typeLabel .
  FILTER ( LANG( ?typeLabel ) = "en" ) .
  OPTIONAL {
    wd:Q507154 wdt:P18 ?image .
  }
}
ORDER BY ?companyLabel ?typeLabel
LIMIT 200

Show me the name, business category, and logo of Novartis in English.

Retrieve the English label of Novartis, the English labels of the types it belongs to, and its associated image from Wikimedia Commons.

SELECT ?var1 ?var2Label ?var3 ?var4Label ?var5 WHERE { <http://www.bigdata.com/queryHints#Query> <http://www.bigdata.com/queryHints#optimizer> "None". { BIND ( <http://www.wikidata.org/entity/Q507154> AS ?var3 ). BIND ( "N/A" AS ?var1 ). BIND ( "identity"@en AS ?var2Label ). } ?var3 <http://www.w3.org/2000/01/rdf-schema#label> ?var4Label . FILTER ( ( ( LANG ( ?var4Label ) = "en" ) ) ) . FILTER ( ( ( LANG ( ?var2Label ) = "en" ) ) ) . OPTIONAL { ?var6 <http://www.wikidata.org/prop/direct/P18> ?var5 . } } ORDER BY ASC( ?var1 )ASC( ?var3 ) LIMIT 200


Question: CEOs of companies in the DAX stock index

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?companyLabel ?ceoLabel WHERE {
  ?company wdt:P361 wd:Q155718 .
  OPTIONAL {
    ?company wdt:P169 ?ceo .
    ?ceo rdfs:label ?ceoLabel .
    FILTER ( LANG( ?ceoLabel ) = "en" )
  }
  ?company rdfs:label ?companyLabel .
  FILTER ( LANG( ?companyLabel ) = "en" )
}

Who are the CEOs of the companies that make up the DAX index?

List the English labels of companies in the DAX index along with their chief executive officers, if available.

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


Question: Most specific common class between China and Abu Dhabi in Wikidata hierarchy

SELECT ?common (?distChina + ?distAbuDhabi AS ?totalDist)
WHERE {
  {
    SELECT ?common (COUNT(?mid) AS ?distChina)
    WHERE {
      wd:Q148 wdt:P31 ?clsChina .
      ?clsChina wdt:P279* ?mid .
      ?mid wdt:P279+ ?common .
    }
    GROUP BY ?common
  }
  {
    SELECT ?common (COUNT(?mid) AS ?distAbuDhabi)
    WHERE {
      wd:Q1519 wdt:P31 ?clsAbuDhabi .
      ?clsAbuDhabi wdt:P279* ?mid .
      ?mid wdt:P279+ ?common .
    }
    GROUP BY ?common
  }
}
ORDER BY ASC(?totalDist)
LIMIT 1

What is the most specific category that both China and Abu Dhabi belong to, based on their class hierarchy?

Find the class that minimizes the total distance from both China and Abu Dhabi in the subclass tree.

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/Q148> ; <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/Q1519> ; <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 museum is associated with the exhibition catalogue "Exhibition catalogue of the Museum of Modern Art, New York", and how many language versions of its Wikipedia page exist?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
SELECT ?item(COUNT(?site) AS ?sitelinkCount) WHERE {
  ?item wdt:P972 wd:Q5460604 .
  ?site schema:about ?item .
  FILTER(STRSTARTS(STR(?site) , "https://"))
}
GROUP BY ?item
ORDER BY ASC(?item)

How many Wikipedia articles are there about the institution listed in the MoMA exhibition catalogue?

Which entity is cataloged under MoMA’s exhibition catalogue, and how many Wikipedia sitelinks does it have?

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P972> <http://www.wikidata.org/entity/Q5460604> . OPTIONAL { ?var1 <http://wikiba.se/ontology#sitelinks> ?var2 . } } ORDER BY ASC( ?var1 )


Question: Companies in Croatia with their names in all languages

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 ?company ?label WHERE {
  ?company wdt:P31 ?type .
  ?type wdt:P279 * wd:Q783794 .
  ?company wdt:P17 wd:Q224 .
  ?company rdfs:label ?label .
}
ORDER BY ASC(?label)

What are all the companies located in Croatia, and what are their names in different languages?

List all entities in Croatia that are companies (including subclasses like shipyards or software firms), along with their labels in every language they are available in.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> ?var3 . ?var3 <http://www.wikidata.org/prop/direct/P279> * <http://www.wikidata.org/entity/Q783794> . ?var1 <http://www.wikidata.org/prop/direct/P17> <http://www.wikidata.org/entity/Q224> . ?var1 <http://www.w3.org/2000/01/rdf-schema#label> ?var2 . } ORDER BY ASC( ?var2 )


Question: Which Wikidata items have the Twitter handles "palmashow", "canalplus", "Le_Figaro", or "T_Ardisson"?

SELECT ?item ?handle WHERE { ?item wdt:P2002 ?handle . VALUES (?handle) { ("palmashow") ("canalplus") ("Le_Figaro") ("T_Ardisson") } }

Can you find the Wikidata entities associated with the Twitter usernames "palmashow", "canalplus", "Le_Figaro", and "T_Ardisson"?

List the Wikidata items that are linked to the Twitter accounts @palmashow, @canalplus, @Le_Figaro, and @T_Ardisson.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2002> ?var2 ; <http://wikiba.se/ontology#sitelinks> ?var3 . VALUES ( ?var2 ) { ( "vinzpujol" ) ( "C8TV" ) ( "Palmashow" ) ( "GregLudig" ) ( "string1" ) ( "CStar" ) ( "string2" ) ( "string3" ) ( "string4" ) ( "string5" ) ( "string6" ) ( "string7" ) ( "TPMP" ) ( "string8" ) ( "canalplus" ) ( "string9" ) ( "string10" ) ( "string11" ) ( "string12" ) ( "gbviret" ) ( "ptoleme20" ) ( "string13" ) ( "MerindolL" ) ( "string14" ) ( "manucs2277" ) ( "Crawski" ) ( "string15" ) ( "VivendiEnt" ) ( "MarieMazur" ) ( "nnesocanal" ) ( "string16" ) ( "stefberto" ) ( "string17" ) ( "string18" ) ( "string19" ) ( "string20" ) ( "FlabProd" ) ( "string21" ) ( "string22" ) ( "string23" ) ( "Le_Figaro" ) ( "TVConseil" ) ( "string24" ) ( "T_Ardisson" ) ( "string25" ) ( "string26" ) ( "string27" ) ( "lolobababa" ) ( "string28" ) ( "string29" ) } } ORDER BY ASC( ?var3 )


Question: Which Wikidata items have Twitter handles "Le_Figaro" or "YouTube"?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?item ?twitterHandle WHERE {
  ?item wdt:P2002 ?twitterHandle .
  VALUES ?twitterHandle {
    "Le_Figaro" "YouTube"
  }
}

What are the Wikidata entities associated with the Twitter usernames "Le_Figaro" and "YouTube"?

Show me the Wikidata items for the Twitter accounts "Le_Figaro" and "YouTube".

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2002> ?var2 ; <http://wikiba.se/ontology#sitelinks> ?var3 . VALUES ( ?var2 ) { ( "MatHood" ) ( "string1" ) ( "string2" ) ( "string3" ) ( "string4" ) ( "string5" ) ( "string6" ) ( "string7" ) ( "TiffanieD" ) ( "string8" ) ( "string9" ) ( "Le_Figaro" ) ( "string10" ) ( "string11" ) ( "string12" ) ( "string13" ) ( "ClemcR" ) ( "string14" ) ( "string15" ) ( "YouTube" ) ( "string16" ) ( "string17" ) ( "string18" ) } } ORDER BY ASC( ?var3 )


Question: Items in museum collections with placeholder creation dates later than acquisition dates

PREFIX p: <http://www.wikidata.org/prop/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?item ?itemLabel ?inceptionDate ?acquisitionDate WHERE {
  ?item wdt:P571 ?inceptionDate ; p:P195 ?collectionStatement .
  ?collectionStatement pq:P580 ?acquisitionDate .
  ?item rdfs:label ?itemLabel .
  FILTER(?inceptionDate > ?acquisitionDate)
}

Which artworks or objects in museum collections have an invented creation date (like 2000) that is after the date they were added to the collection?

Show me items in collections where the recorded creation date is later than the date they were acquired, likely indicating incomplete data.

SELECT ?var1 ?var1Label ?var2 ?var3 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P571> ?var2 ; <http://www.wikidata.org/prop/P195> ?var4 . ?var4 <http://www.wikidata.org/prop/qualifier/P580> ?var3 . FILTER ( ( ( ?var2 > ?var3 ) ) ) . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } }


Question: Human settlements in the United States, same country as Worcester, Massachusetts.

SELECT DISTINCT ?settlement ?settlementLabel ?country ?countryLabel WHERE { wd:Q49179 wdt:P17 ?country . ?settlement wdt:P31/wdt:P279* wd:Q486972 ; wdt:P17 ?country . ?settlement rdfs:label ?settlementLabel . ?country rdfs:label ?countryLabel . FILTER(LANG(?settlementLabel) = "en") FILTER(LANG(?countryLabel) = "en") } LIMIT 10

What cities and towns are located in the United States, the country where Worcester, Massachusetts is located?

List the names of human settlements and their country, where the country is the same as that of Worcester, Massachusetts.

SELECT DISTINCT ?var1 ?var2Label ?var3 ?var3Label WHERE { ?var1 <http://www.wikidata.org/prop/direct/P279> * <http://www.wikidata.org/entity/Q486972> . ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q49179> . ?var1 <http://www.wikidata.org/prop/direct/P17> ?var3 . ?var1 <http://www.w3.org/2000/01/rdf-schema#label> ?var2Label . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } } LIMIT 10


Question: Creative works with freely usable images on Commons whose creators died after 1923, including their creation date and country of citizenship.

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?work ?inception ?deathDate ?country WHERE {
  ?work wdt:P4765 ?imageURL .
  ?work wdt:P170 ?creator .
  ?creator wdt:P570 ?deathDate .
  FILTER ( YEAR( ?deathDate ) > 1923 ) .
  OPTIONAL {
    ?work wdt:P571 ?inception .
  }
  OPTIONAL {
    ?creator wdt:P27 ?country .
  }
}

Which artworks have publicly available images on Wikimedia Commons and were created by artists who died after 1923? Show their creation year and the artist’s country.

List all creative works that have a Commons-compatible image, along with the year they were created (if known) and the country of citizenship of their creators — but only include those whose creators died after 1923.

SELECT ?var1 ?var2 ?var3 ?var4 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P4765> ?var5 . { ?var1 <http://www.wikidata.org/prop/direct/P571> ?var2 . FILTER ( ( ( YEAR ( ?var2 ) > "1923"^^<http://www.w3.org/2001/XMLSchema#integer> ) ) ) . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P170> ?var6 . ?var6 <http://www.wikidata.org/prop/direct/P570> ?var3 . } } UNION { ?var1 <http://www.wikidata.org/prop/direct/P170> ?var6 . ?var6 <http://www.wikidata.org/prop/direct/P570> ?var3 . FILTER ( ( ( YEAR ( ?var3 ) > "1923"^^<http://www.w3.org/2001/XMLSchema#integer> ) ) ) . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P571> ?var2 . } } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P170> ?var6 . ?var6 <http://www.wikidata.org/prop/direct/P27> ?var4 . } }


Question: How many paintings on Wikidata have a creator and/or an image, categorized by presence or absence of each?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ( IF( ?hasCreator = 1 , IF( ?hasImage = 1 , "Has creator and image" , "Has creator, no image" ) , IF( ?hasImage = 1 , "No creator, has image" , "No creator and no image" ) ) AS ?category ) ?count WHERE {
  {
    SELECT ?hasCreator ?hasImage ( COUNT( DISTINCT ?painting ) AS ?count ) WHERE {
      ?painting wdt:P31 wd:Q3305213 .
      OPTIONAL {
        ?painting wdt:P170 ?creator .
      }
      OPTIONAL {
        ?painting wdt:P18 ?image .
      }
      BIND( IF( BOUND( ?creator ) , 1 , 0 ) AS ?hasCreator ) .
      BIND( IF( BOUND( ?image ) , 1 , 0 ) AS ?hasImage ) .
    }
    GROUP BY ?hasCreator ?hasImage
  }
}
ORDER BY DESC ( ?count )

What is the distribution of paintings based on whether they have a creator and/or an image attached?

Show me the count of paintings grouped into four categories: those with both a creator and an image, those with only a creator, those with only an image, and those with neither.

SELECT( IF ( ( ?var1 = "1"^^<http://www.w3.org/2001/XMLSchema#integer> ), IF ( ( ?var2 = "1"^^<http://www.w3.org/2001/XMLSchema#integer> ), "string1", "string2" ) , IF ( ( ?var2 = "1"^^<http://www.w3.org/2001/XMLSchema#integer> ), "string3", "string4" ) ) AS ?var3Label ) ?var4 WHERE { { SELECT ?var1 ?var2 ( COUNT ( DISTINCT ?var3 ) AS ?var4 ) WHERE { ?var3 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q3305213> . OPTIONAL { ?var3 <http://www.wikidata.org/prop/direct/P170> ?var5 . } OPTIONAL { ?var3 <http://www.wikidata.org/prop/direct/P18> ?var6 . } BIND ( IF ( BOUND ( ?var5 ) ,"1"^^<http://www.w3.org/2001/XMLSchema#integer> ,"0"^^<http://www.w3.org/2001/XMLSchema#integer> ) AS ?var1 ). BIND ( IF ( BOUND ( ?var6 ) ,"1"^^<http://www.w3.org/2001/XMLSchema#integer> ,"0"^^<http://www.w3.org/2001/XMLSchema#integer> ) AS ?var2 ). } GROUP BY ?var1 ?var2 } } ORDER BY DESC( ?var4 )


Question: List all types of engine configurations.

SELECT ?engine ?engineLabel WHERE { ?engine wdt:P31 wd:Q2576663 . ?engine rdfs:label ?engineLabel . FILTER(LANG(?engineLabel) = "en") } LIMIT 200

What are the different types of engine arrangements recognized in Wikidata?

Show me the names of all engine configurations, such as V6 or rotary engine, in English.

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


Question: Which Wikidata entities have Twitter handles "lemondefr", "lequipe", or "RudiGarcia"?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX schema: <http://schema.org/>
SELECT ?item ?twitterHandle WHERE {
  ?item wdt:P2002 ?twitterHandle .
  VALUES ?twitterHandle {
    "lemondefr" "lequipe" "RudiGarcia"
  }
  .
  ?sitelink schema:about ?item ; schema:isPartOf ?wiki .
  FILTER(STRSTARTS(STR(?sitelink) , "https://"))
}
GROUP BY ?item ?twitterHandle
ORDER BY ASC(COUNT(?sitelink))

Who are the people or organizations on Wikidata with the Twitter usernames "lemondefr", "lequipe", or "RudiGarcia"?

List the entities on Wikidata linked to the Twitter accounts @lemondefr, @lequipe, and @RudiGarcia, sorted by how many Wikipedia pages they have.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2002> ?var2 ; <http://wikiba.se/ontology#sitelinks> ?var3 . VALUES ( ?var2 ) { ( "lephoceen" ) ( "string1" ) ( "string2" ) ( "lemondefr" ) ( "lequipe" ) ( "Giugiuhoy" ) ( "string3" ) ( "RudiGarcia" ) ( "string4" ) } } ORDER BY ASC( ?var3 )


Question: Which Wikidata items have Twitter usernames mySociety, ash_crow, Calimaq, Pyb75, or wikidata?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?item ?username WHERE {
  ?item wdt:P2002 ?username .
  VALUES ?username {
    "mySociety" "ash_crow" "Calimaq" "Pyb75" "wikidata"
  }
}

Who are the people or organizations on Wikidata with the Twitter handles @mySociety, @ash_crow, @Calimaq, @Pyb75, or @wikidata?

List all Wikidata entities that are associated with the Twitter usernames: mySociety, ash_crow, Calimaq, Pyb75, and wikidata.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2002> ?var2 ; <http://wikiba.se/ontology#sitelinks> ?var3 . VALUES ( ?var2 ) { ( "MIDImyers" ) ( "ash_crow" ) ( "string1" ) ( "nojhan" ) ( "string2" ) ( "string3" ) ( "fandeSassa" ) ( "Pyb75" ) ( "Calimaq" ) ( "string4" ) ( "string5" ) ( "string6" ) ( "emptywheel" ) ( "string7" ) ( "string8" ) ( "string9" ) ( "string10" ) ( "wikidata" ) ( "string11" ) ( "belett" ) ( "string12" ) ( "EJBrand" ) ( "Chaoborus" ) ( "string13" ) ( "string14" ) ( "GaelBriand" ) ( "mySociety" ) ( "string15" ) ( "string16" ) ( "jonnysun" ) ( "NawakNawak" ) ( "string17" ) ( "string18" ) ( "string19" ) ( "string20" ) ( "string21" ) ( "adwords" ) ( "string22" ) ( "string23" ) ( "MaelLeHir" ) ( "La_Chat_9" ) ( "TradCatFem" ) ( "Pontifex" ) ( "fagerving" ) ( "gblardone" ) ( "Auregann" ) ( "GoogleFR" ) ( "string24" ) ( "joelapompe" ) ( "string25" ) ( "string26" ) ( "abta78" ) ( "cholten99" ) } } ORDER BY ASC( ?var3 )


Question: Posters with their images, collections, and creators

SELECT ?poster ?posterLabel ?image ?collectionLabel ?creatorLabel WHERE { ?poster (wdt:P31/wdt:P279*) wd:Q429785 . ?poster wdt:P18 ?image . ?poster wdt:P195 ?collection . ?poster wdt:P170 ?creator . ?poster rdfs:label ?posterLabel . ?collection rdfs:label ?collectionLabel . ?creator rdfs:label ?creatorLabel . FILTER(LANG(?posterLabel) = "en") FILTER(LANG(?collectionLabel) = "en") FILTER(LANG(?creatorLabel) = "en") }

What are the posters, their creators, and the collections they belong to, along with their images?

Show me posters from the art genre, including their images, the museums or archives that hold them, and their artists.

SELECT ?var1 ?var1Label ?var2 ?var3Label ?var4Label WHERE { ?var1 ( <http://www.wikidata.org/prop/direct/P31> / <http://www.wikidata.org/prop/direct/279> *) <http://www.wikidata.org/entity/Q429785> . ?var1 <http://www.wikidata.org/prop/direct/P18> ?var2 . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P276> ?var5 . } ?var1 <http://www.wikidata.org/prop/direct/P195> ?var3 . ?var1 <http://www.wikidata.org/prop/direct/P170> ?var4 . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,fr,de,it,pl". } }


Question: File extensions and logos for software like Snap! and XBRL

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

What file extensions are associated with each software or file format, and what is its official image on Wikimedia Commons?

Show me the file extensions and corresponding logo images for software and file formats in English.

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


Question: What is the English label and description of Novartis?

SELECT ?label ?description ?officialName WHERE { wd:Q507154 rdfs:label ?label . FILTER(LANG(?label) = "en") OPTIONAL { wd:Q507154 schema:description ?description . FILTER(LANG(?description) = "en") } OPTIONAL { wd:Q507154 wdt:P1448 ?officialName . FILTER(LANG(?officialName) = "en") } }

Can you tell me the official name and a brief description of the pharmaceutical company Novartis in English?

What does Wikidata say about Novartis in English? Include its name and description.

SELECT * WHERE { { BIND ( ?var1 AS ?var2 ). <http://www.wikidata.org/entity/Q507154> ?var3 ?var1 . FILTER ( ( !( isIRI ( ?var1 ) ) ) ) . FILTER ( ( ( LANG ( ?var2 ) = "en" ) ) ) . } UNION { BIND ( ?var4 AS ?var2 ). <http://www.wikidata.org/entity/Q507154> ?var3 ?var1 . ?var1 ?var5 ?var4 . FILTER ( ( isIRI ( ?var1 ) ) ) . FILTER ( ( !( REGEX ( STR ( ?var1 ) , "statement/" ) ) ) ) . FILTER ( ( ( LANG ( ?var2 ) = "en" ) ) ) . } UNION { BIND ( ?var6 AS ?var2 ). <http://www.wikidata.org/entity/Q507154> ?var3 ?var1 . ?var1 ?var5 ?var4 . ?var4 ?var7 ?var6 . FILTER ( ( REGEX ( STR ( ?var5 ) , "string1" ) ) ) . FILTER ( ( isIRI ( ?var4 ) ) ) . FILTER ( ( REGEX ( STR ( ?var1 ) , "statement/" ) ) ) . FILTER ( ( ( LANG ( ?var2 ) = "en" ) ) ) . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: Buildings in Amsterdam

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 ?building ?buildingLabel WHERE {
  ?building wdt:P31 wd:Q41176 ; wdt:P131 wd:Q9899 .
  ?building rdfs:label ?buildingLabel .
  FILTER ( LANG( ?buildingLabel ) = "en" )
}

What are the buildings located in Amsterdam?

List the English labels of all buildings in Amsterdam.

SELECT ?var1 WHERE { <https://adamlink.nl/geo/building/meerhuizen/569> <https://www.wikidata.org/wiki/Property:P31> <http://www.wikidata.org/entity/Q13691604> ; <https://www.wikidata.org/wiki/Property:P131> <http://www.wikidata.org/entity/Q9899> . }


Question: Building named Arti et Amicitiae located in Amsterdam

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 ?building WHERE {
  ?building rdfs:label "Arti et Amicitiae" @en ; wdt:P31 wd:Q41176 ; wdt:P131 wd:Q9899 .
}

What is the building in Amsterdam called Arti et Amicitiae?

Find the building in Amsterdam that is named Arti et Amicitiae.

SELECT ?var1 WHERE { <https://adamlink.nl/geo/building/arti-et-amicitiae/185> <https://www.wikidata.org/wiki/Property:P31> <http://www.wikidata.org/entity/Q13691604> ; <https://www.wikidata.org/wiki/Property:P131> <http://www.wikidata.org/entity/Q9899> . }


Question: Items with a copyright license and their English labels.

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?item ?itemLabel WHERE {
  ?item wdt:P275 ?license .
  ?item rdfs:label ?itemLabel .
  FILTER ( LANG( ?itemLabel ) = 'en' )
}
LIMIT 10

What are some works or publications that are licensed under a copyright license, and what are their English names?

Show me the English names of items that have a copyright license.

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


Question: Stock market indices with their Japanese alternative names and English labels.

SELECT ?index ?labelEn ?labelJa WHERE { ?index wdt:P31 wd:Q223371 . OPTIONAL { ?index rdfs:label ?labelEn . FILTER(LANG(?labelEn) = "en") } OPTIONAL { ?index skos:altLabel ?labelJa . FILTER(LANG(?labelJa) = "ja") } }

What are the English names and Japanese alternative names of all stock market indices?

List all stock market indices along with their English labels and any Japanese alternative labels.

SELECT ?var1 ?var1Label ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q223371> . OPTIONAL { ?var1 <http://www.w3.org/2004/02/skos/core#altLabel> ?var2 . FILTER ( ( ( LANG ( ?var2 ) = "ja" ) ) ) . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "ja". } }


Question: What buildings are located in Amsterdam-Centrum?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?building WHERE {
  ?building wdt:P31 wd:Q41176 ; wdt:P131 wd:Q9899 .
}

List all the buildings in the Amsterdam-Centrum district.

Can you show me the buildings in Amsterdam-Centrum?

SELECT ?var1 WHERE { <https://adamlink.nl/geo/building/gevelsteen-leggen-van-eerste-steen/297> <https://www.wikidata.org/wiki/Property:P31> <http://www.wikidata.org/entity/Q13691604> ; <https://www.wikidata.org/wiki/Property:P131> <http://www.wikidata.org/entity/Q9899> . }


Question: Which file formats in Wikidata share the same PRONOM identifier (PUID)?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT DISTINCT ?format1 ?format1Label ?format2 ?format2Label ?puid WHERE {
  ?format1 wdt:P2748 ?puid .
  ?format2 wdt:P2748 ?puid .
  FILTER ( ?format1 != ?format2 && STR( ?format1 ) < STR( ?format2 ) ) .
  ?format1 rdfs:label ?format1Label .
  ?format2 rdfs:label ?format2Label .
  FILTER ( LANG( ?format1Label ) = "en" && LANG( ?format2Label ) = "en" )
}
LIMIT 100

What pairs of distinct file format entries in Wikidata have identical PRONOM PUIDs, and what are their English labels?

Find duplicate file format entries in Wikidata that are assigned the same PRONOM identifier, and list their English names to help identify potential merges.

SELECT DISTINCT ?var1 ?var1Label ?var2 ?var2Label ?var3 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2748> ?var3 . ?var2 <http://www.wikidata.org/prop/direct/P2748> ?var3 . FILTER ( ( ( ?var1 != ?var2 ) && ( STR ( ?var1 ) < STR ( ?var2 ) ) ) ) . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } } LIMIT 100


Question: What are the known models of baby monitors?

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

Which specific baby monitor models are documented in Wikidata?

List the named baby monitor devices that exist as instances in Wikidata.

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


Question: What are the properties and their values associated with Novartis, along with their English labels?

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?prop ?propLabel ?obj ?objLabel WHERE {
  wd:Q507154 ?prop ?obj .
  BIND(IRI(REPLACE(STR(?prop) , "http://www.wikidata.org/prop/direct/" , "http://www.wikidata.org/entity/")) AS ?propEntity)
  .
  ?propEntity rdfs:label ?propLabel .
  FILTER(LANG(?propLabel) = "en")
  OPTIONAL {
    ?obj rdfs:label ?objLabel .
    FILTER(LANG(?objLabel) = "en")
  }
}
ORDER BY ?prop ?obj
LIMIT 200

Can you show me all the facts about Novartis in English, including the names of the properties and the labels of the values?

List all the direct statements about Novartis, showing the English names of the properties and any English labels of the objects.

SELECT ?var1 ?var2Label ?var3 ?var4Label WHERE { <http://www.bigdata.com/queryHints#Query> <http://www.bigdata.com/queryHints#optimizer> "None". { BIND ( <http://www.wikidata.org/entity/Q507154> AS ?var3 ). BIND ( "N/A" AS ?var1 ). BIND ( "identity"@en AS ?var2Label ). } UNION { <http://www.wikidata.org/entity/Q507154> ?var1 ?var3 . ?var5 ?var6 ?var1 . FILTER ( ( !( isIRI ( ?var1 ) ) ) ) . } FILTER ( ( ( LANG ( ?var4Label ) = "en" ) ) ) . FILTER ( ( ( LANG ( ?var2Label ) = "en" ) ) ) . } ORDER BY ASC( ?var1 )ASC( ?var3 ) LIMIT 200


Question: What are all the properties and values associated with the company Novartis?

SELECT ?property ?value ?valueLabel WHERE { wd:Q507154 ?property ?value . OPTIONAL { ?value rdfs:label ?valueLabel . FILTER(LANG(?valueLabel) = "en") } } ORDER BY ?property

Can you show me all the information available about Novartis on Wikidata, including the English names of any related entities?

List all statements about Novartis, and if any of the objects are entities, please include their English labels.

SELECT * WHERE { <http://www.bigdata.com/queryHints#Query> <http://www.bigdata.com/queryHints#optimizer> "None". { ?var1 ?var2Label "Novartis"@en . } UNION { ?var1 ?var2Label "Novartis"@en . ?var1 ?var3 ?var4 . FILTER ( ( isLITERAL ( ?var4 ) ) ) . FILTER ( ( ( LANG ( ?var4 ) = "en" ) ) ) . } UNION { BIND ( ?var5 AS ?var4 ). ?var1 ?var2Label "Novartis"@en . ?var1 ?var3 ?var5 . ?var3 ?var6 ?var7 . FILTER ( ( isIRI ( ?var5 ) && !( REGEX ( STR ( ?var5 ) , "string1" ) ) ) ) . } UNION { ?var1 ?var2Label "Novartis"@en . ?var1 ?var3 ?var5 . ?var3 ?var6 ?var7 . FILTER ( ( isIRI ( ?var5 ) && REGEX ( STR ( ?var5 ) , "string1" ) ) ) . ?var5 <http://www.w3.org/2000/01/rdf-schema#label> ?var4 . FILTER ( ( ( LANG ( ?var4 ) = "en" ) ) ) . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: What type of structure is the Boterwaag in Amsterdam, and where is it located?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?typeLabel ?locationLabel WHERE {
  wd:Q2382331 wdt:P31 ?type ; wdt:P131 ?location .
  ?type rdfs:label ?typeLabel .
  ?location rdfs:label ?locationLabel .
  FILTER ( LANG( ?typeLabel ) = 'en' ) .
  FILTER ( LANG( ?locationLabel ) = 'en' ) .
}

Is the Boterwaag in Amsterdam a building or a city gate, and which city is it in?

Can you tell me the classification and location of the historic Boterwaag structure in Amsterdam?

SELECT ?var1 WHERE { <https://adamlink.nl/geo/building/boterwaag/589> <https://www.wikidata.org/wiki/Property:P31> <http://www.wikidata.org/entity/Q13691604> ; <https://www.wikidata.org/wiki/Property:P131> <http://www.wikidata.org/entity/Q9899> . }


Question: What are some car brands owned by automobile manufacturers?

SELECT ?carBrand ?carBrandLabel WHERE { ?carBrand wdt:P127 ?manufacturer . ?carBrand wdt:P31 wd:Q10429667 . ?manufacturer wdt:P31 wd:Q786820 . ?carBrand rdfs:label ?carBrandLabel . FILTER(LANG(?carBrandLabel) = "en") } LIMIT 10

List car brands and their English labels that are subsidiaries of car manufacturers.

Which automotive brands are owned by companies that manufacture automobiles?

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


Question: Public companies and their stock exchanges

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?company ?stockExchange WHERE {
  ?company wdt:P31 wd:Q891723 .
  ?company wdt:P414 ?stockExchange .
}
LIMIT 100

Which stock exchanges are public companies listed on?

Show me a list of public companies along with the stock exchanges where they are traded.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q891723> . ?var1 <http://www.wikidata.org/prop/direct/P414> ?var2 . } LIMIT 100


Question: Top software applications by number of file formats they can export to.

SELECT ?software ?softwareLabel (COUNT(?format) AS ?formatCount) WHERE { ?software wdt:P31/wdt:P279* wd:Q7397 . ?software wdt:P1073 ?format . ?software rdfs:label ?softwareLabel . FILTER(LANG(?softwareLabel) = "en") } GROUP BY ?software ?softwareLabel ORDER BY DESC(?formatCount)

Which software programs can write to the most file formats, and how many formats do they support?

List software applications in descending order of the number of file formats they support, along with their names and counts.

SELECT ?var1 ?var1Label ( COUNT ( ?var2 ) AS ?var3 ) WHERE { ?var1 ( <http://www.wikidata.org/prop/P31> / <http://www.wikidata.org/prop/statement/P31> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q7397> . ?var1 <http://www.wikidata.org/prop/direct/P1073> ?var2 . } GROUP BY ?var1 ?var1Label ORDER BY DESC( ?var3 )


Question: What is the official website of the Agda programming language, and in which language is it written?

SELECT ?website ?language WHERE { wd:Q20479 wdt:P856 ?website . wd:Q20479 p:P856 ?statement . ?statement pq:P407 ?language . }

Can you tell me the URL for Agda’s official website and the language it uses?

Agda’s official website is https://wiki.portal.chalmers.se/agda/pmwiki.php — what language is that site in?

SELECT ?var1 ?var2 WHERE { <http://www.wikidata.org/entity/statement/Q20479-bac565fe-4498-d777-c926-80baa0fce5ae> ?var1 ?var2 . }


Question: What are the file systems and when were they released?

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?fileSystem ?fileSystemLabel ?releaseDate WHERE {
  ?fileSystem ( wdt:P31 / wdt:P279 * ) wd:Q174989 .
  OPTIONAL {
    ?fileSystem wdt:P577 ?releaseDate .
  }
  ?fileSystem rdfs:label ?fileSystemLabel .
  FILTER ( LANG( ?fileSystemLabel ) = "en" )
}

Can you list all file systems (including their subclasses) along with their publication dates?

Which file systems have known release dates, and what are their names?

SELECT DISTINCT ?var1 ?var1Label ?var2 WHERE { ?var1 ( <http://www.wikidata.org/prop/direct/P31> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q174989> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P577> ?var2 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } }


Question: Creative works inspired by creations of Italian-born artists, with their types, creators, and images.

SELECT ?work ?workLabel ?typeLabel ?inspirationLabel ?creatorLabel ?image WHERE { ?work wdt:P941 ?inspiration ; wdt:P31 ?type ; rdfs:label ?workLabel . ?inspiration wdt:P170 ?creator ; rdfs:label ?inspirationLabel . ?creator wdt:P19 ?birthplace ; rdfs:label ?creatorLabel . ?birthplace wdt:P17 wd:Q38 . ?type rdfs:label ?typeLabel . OPTIONAL { ?work wdt:P18 ?image . } FILTER(LANG(?workLabel) = "en") FILTER(LANG(?inspirationLabel) = "en") FILTER(LANG(?creatorLabel) = "en") FILTER(LANG(?typeLabel) = "en") }

What are the artworks inspired by works created by people born in Italy, and who are their creators and types?

List creative works that were inspired by something made by someone born in Italy, including their type, the inspiration, the creator, and an image if available.

SELECT ?var1 ?var1Label ?var2Label ?var3Label ?var4Label ?var5 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P941> ?var3 ; <http://www.wikidata.org/prop/direct/P31> ?var2 . ?var3 <http://www.wikidata.org/prop/direct/P170> ?var4 . ?var4 <http://www.wikidata.org/prop/direct/P19> ?var6 . ?var6 <http://www.wikidata.org/prop/direct/P17> <http://www.wikidata.org/entity/Q38> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P18> ?var5 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "de,en". } }


Question: What type of entity is Cadillac, Michigan in Wikidata?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?instanceType WHERE {
  wd:Q1025149 wdt:P31 ?instanceType .
}

Instance type of Cadillac, Michigan in Wikidata.

Tell me what category Cadillac, Michigan belongs to in Wikidata.

SELECT ?var1 WHERE { <http://dbpedia.org/resource/Cadillac,_Michigan> <http://www.wikidata.org/prop/direct/P31> ?var2 . }


Question: Entities with PermID and their types

SELECT ?item ?type WHERE { ?item wdt:P31 ?type . ?item wdt:P3347 ?permId . }

Which entities have a PermID and what are their types?

List all items that are assigned a Thomson Reuters PermID along with the classes they belong to.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> ?var2 . ?var1 <http://www.wikidata.org/prop/direct/P3347> ?var3 . }


Question: What are the English and German Wikipedia pages for the movie with IMDb ID tt1470023?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX schema: <http://schema.org/>
SELECT ?movie ?wiki WHERE {
  ?movie wdt:P345 "tt1470023" .
  ?wiki schema:about ?movie ; schema:inLanguage ?lang .
  FILTER(?lang IN("en" , "de"))
}

Which Wikipedia pages in English and German are about the movie MacGruber?

Show me the English and German Wikipedia links for the film MacGruber, identified by its IMDb ID tt1470023.

SELECT ?var1 ?var2 ?var3 WHERE { { ?var1 <http://www.wikidata.org/prop/direct/P345> "tt1470822". } ?var2 <http://schema.org/about> ?var1 . { ?var2 <http://schema.org/inLanguage> "en". } UNION { ?var2 <http://schema.org/inLanguage> "de". } ?var1 <http://www.wikidata.org/prop/direct/P345> ?var3 . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: File formats developed by Autodesk with their file extensions and MIME types.

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?format ?formatLabel ?extension ?mimeType WHERE {
  ?format wdt:P31 / wdt:P279 * wd:Q235557 .
  ?format wdt:P178 wd:Q628051 .
  OPTIONAL {
    ?format wdt:P1195 ?extension .
  }
  OPTIONAL {
    ?format wdt:P1163 ?mimeType .
  }
  ?format rdfs:label ?formatLabel .
  FILTER(LANG(?formatLabel) = "en")
}

What are the file formats created by Autodesk, along with their file extensions and media types?

List all file formats (including subclasses) developed by Autodesk, showing their English names, file extensions (like .dxf or .rvt), and associated MIME types (like image/vnd.dxf).

SELECT ?var1 ?var1Label ?var2 ?var3 WHERE { ?var1 ( <http://www.wikidata.org/prop/P31> / <http://www.wikidata.org/prop/statement/P31> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q235557> . ?var1 <http://www.wikidata.org/prop/direct/P178> <http://www.wikidata.org/entity/Q628051> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P1195> ?var2 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P1163> ?var3 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } }


Question: Vehicles and machines that have an engine as a part.

SELECT ?item ?itemLabel WHERE { ?item wdt:P527 wd:Q44167 . ?item rdfs:label ?itemLabel . FILTER(LANG(?itemLabel) = "en") }

What types of vehicles and machines contain an engine?

List all machines that are powered by an engine.

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


Question: Churches in Denmark with their coordinates and English names.

SELECT ?church ?label ?coordinates WHERE { ?church wdt:P31 wd:Q16970 ; wdt:P17 wd:Q35 . OPTIONAL { ?church wdt:P625 ?coordinates . } ?church rdfs:label ?label . FILTER(LANG(?label) = "en") }

What are the English names and geographic coordinates of church buildings in Denmark?

List all church buildings in Denmark along with their English labels and locations.

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


Question: Programming languages that are both scripting languages and object-based languages.

SELECT ?language ?languageLabel ?property WHERE { ?language ?property wd:Q187432 . ?language ?property wd:Q899523 . ?language rdfs:label ?languageLabel . FILTER(LANG(?languageLabel) = "en") }

Which programming languages are both scripting languages and object-oriented languages?

List all programming languages that are instances of both scripting languages and object-based languages.

SELECT ?var1 ?var1Label ?var2 WHERE { ?var1 ?var2 <http://www.wikidata.org/entity/Q187432> . ?var1 ?var2 <http://www.wikidata.org/entity/Q899523> . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: Companies with ticker symbol IBM and their stock exchange

PREFIX ps: <http://www.wikidata.org/prop/statement/>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT DISTINCT ?company ?companyLabel ?exchange ?exchangeLabel ?ticker WHERE {
  ?company wdt:P31 / wdt:P279 * wd:Q4830453 ; p:P414 ?statement .
  ?statement ps:P414 ?exchange ; pq:P249 ?ticker .
  FILTER(LCASE(STR(?ticker)) = "ibm")
  .
  ?company rdfs:label ?companyLabel .
  ?exchange rdfs:label ?exchangeLabel .
  FILTER(LANG(?companyLabel) = "en")
  .
  FILTER(LANG(?exchangeLabel) = "en")
}

On which stock exchange is IBM listed, and what is its ticker symbol?

Show me the stock exchange where IBM is traded, along with its ticker symbol.

SELECT DISTINCT ?var1 ?var1Label ?var2 ?var2Label ?var3 WHERE { ?var1 ( <http://www.wikidata.org/prop/direct/P31> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q4830453> . { ?var1 <http://www.wikidata.org/prop/direct/P249> ?var3 . FILTER ( ( ( LCASE ( STR ( ?var3 ) ) = "ibm" ) ) ) . ?var1 <http://www.wikidata.org/prop/P249> ?var4 . ?var4 <http://www.wikidata.org/prop/qualifier/P414> ?var2 . } UNION { ?var1 <http://www.wikidata.org/prop/direct/P414> ?var2 . ?var1 <http://www.wikidata.org/prop/P414> ?var5 . ?var5 <http://www.wikidata.org/prop/qualifier/P249> ?var3 . FILTER ( ( ( LCASE ( STR ( ?var3 ) ) = "ibm" ) ) ) . } UNION { ?var1 <http://www.wikidata.org/prop/direct/P414> ?var2 . ?var1 <http://www.wikidata.org/prop/direct/P249> ?var3 . FILTER ( ( ( LCASE ( STR ( ?var3 ) ) = "ibm" ) ) ) . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } }


Question: Retail chains that are instances of the retail chain class

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

What are some examples of retail chains?

Can you list 10 retail chains along with their names?

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


Question: Number of paintings by female artists per decade since 1400.

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?decade ( COUNT( ?painting ) AS ?count ) WHERE {
  ?painting wdt:P31 wd:Q3305213 .
  ?painting wdt:P571 ?inception .
  ?painting wdt:P170 ?artist .
  ?artist wdt:P21 wd:Q6581072 .
  BIND( YEAR( ?inception ) AS ?year ) .
  BIND( ROUND( ?year / 10 ) * 10 AS ?decade ) .
  FILTER ( ?year > 1400 )
}
GROUP BY ?decade
ORDER BY ASC ( ?decade )

How many paintings created by female artists were made in each decade after 1400?

Show me a breakdown of how many paintings by female artists were created in each decade starting from 1400, grouped and ordered chronologically.

SELECT ?var1 ( COUNT ( ?var1 ) AS ?var2 ) WHERE { BIND ( YEAR ( ?var3 ) AS ?var4 ). BIND ( ( ROUND ( ( ?var4 /"10"^^<http://www.w3.org/2001/XMLSchema#integer> ) ) *"10"^^<http://www.w3.org/2001/XMLSchema#integer> ) AS ?var1 ). ?var5 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q3305213> . ?var5 <http://www.wikidata.org/prop/direct/P571> ?var3 . ?var5 <http://www.wikidata.org/prop/direct/P170> ?var6 . ?var6 <http://www.wikidata.org/prop/direct/P21> <http://www.wikidata.org/entity/Q6581072> . FILTER ( ( ( ?var4 > "1400"^^<http://www.w3.org/2001/XMLSchema#integer> ) ) ) . } GROUP BY ?var1 ORDER BY ASC( ?var1 )


Question: File formats with their extensions and MIME types, sorted by extension and MIME type.

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?format ?extension ?mediaType WHERE {
  ?format wdt:P31 wd:Q235557 ; wdt:P1195 ?extension .
  OPTIONAL {
    ?format wdt:P1163 ?mediaType .
  }
}
ORDER BY ASC(?extension) ASC(?mediaType)

What are the file formats in Wikidata that have file extensions and optionally MIME types, listed in order of extension and then MIME type?

List all file formats along with their file extensions and media types (MIME types), sorted alphabetically by extension and then by media type.

SELECT DISTINCT * WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q6612531> ; <http://www.wikidata.org/prop/direct/P1195> ?var2 . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P1163> ?var3 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } } ORDER BY ASC( ?var2 )ASC( ?var3 )


Question: Number of entities that are parts of the foodservice industry

SELECT (COUNT(?item) AS ?count) WHERE { ?item wdt:P361 wd:Q41958 . }

How many items are classified as parts of the foodservice industry?

List the count of subcategories within the foodservice industry.

SELECT( COUNT ( ?var1 ) AS ?var2 ) WHERE { ?var1 <http://www.wikidata.org/prop/direct/P361> <http://www.wikidata.org/entity/Q41958> . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en, en". } }


Question: File formats and their magic numbers

SELECT ?var1 ?var1Label ?var2 WHERE { ?var1 wdt:P31 wd:Q235557 . ?var1 rdfs:label ?var1Label . ?var1 wdt:P4152 ?var2 . FILTER(LANG(?var1Label) = "en") }

What are the file formats and their identification patterns (magic numbers)?

List file formats along with their file signature hex codes in English.

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


Question: What are the properties associated with the software application category, along with their English labels, the count of their values, and the labels of those values?

SELECT ?property (SAMPLE(?pl) AS ?propertyLabel) (COUNT(?value) AS ?valueCount) (GROUP_CONCAT(?vl; SEPARATOR=", ") AS ?valueLabels) WHERE { wd:Q166142 ?property ?value . ?propertyItem wikibase:directClaim ?property . ?propertyItem rdfs:label ?pl . FILTER(LANG(?pl) = "en") . ?value rdfs:label ?vl . FILTER(LANG(?vl) = "en") } GROUP BY ?property

For the entity "application", list each property used on it, its English name, how many values it has, and what those values are labeled as in English.

Show me a summary of all properties linked to "application" in Wikidata, including the property name in English, how many times it's used, and the English labels of its values.

SELECT ?var1 ( SAMPLE ( ?var2 ) AS ?var2 )( COUNT ( ?var3 ) AS ?var4 )( GROUP_CONCAT ( ?var5 ; SEPARATOR = ", " ) AS ?var5 ) WHERE { <http://www.wikidata.org/entity/Q166142> ?var1 ?var3 . ?var3 <http://www.w3.org/2000/01/rdf-schema#label> ?var5 . FILTER ( ( ( LANG ( ?var5 ) = "en" ) ) ) . ?var6 <http://wikiba.se/ontology#directClaim> ?var1 . ?var6 <http://www.w3.org/2000/01/rdf-schema#label> ?var2 . FILTER ( ( ( LANG ( ?var2 ) = "en" ) ) ) . } GROUP BY ?var1


Question: Subclasses of malware with labels, images, and their direct parent classes

SELECT DISTINCT ?subclass ?subclassLabel ?image ?directSubclassOf WHERE { wd:Q14001 wdt:P279* ?subclass . ?subclass rdfs:label ?subclassLabel . FILTER(LANG(?subclassLabel) = "en") OPTIONAL { ?subclass wdt:P18 ?image } OPTIONAL { ?subclass wdt:P279 ?directSubclassOf } } LIMIT 50

What are the subclasses of malware, their English labels, images, and immediate parent classes?

Show me all ancestors of malware up to any level, along with their English names, images if available, and what class they are directly a subclass of.

SELECT ?var1 ?var1Label ?var2 ?var3 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/Q14001> ; <http://www.bigdata.com/rdf/gas#traversalDirection> "Reverse"; <http://www.bigdata.com/rdf/gas#out> ?var1 ; <http://www.bigdata.com/rdf/gas#out1> ?var4 ; <http://www.bigdata.com/rdf/gas#maxIterations> "4"^^<http://www.w3.org/2001/XMLSchema#integer> ; <http://www.bigdata.com/rdf/gas#linkType> <http://www.wikidata.org/prop/direct/P279> . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P279> ?var3 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P18> ?var2 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: Female and trans women artists with earliest artworks and images on Wikimedia Commons

SELECT ?creator ?creatorLabel ?work ?workLabel ?sampledImage ?minInception WHERE { { SELECT ?creator ?work (SAMPLE(?image) AS ?sampledImage) (MIN(?inception) AS ?minInception) WHERE { ?work wdt:P170 ?creator ; wdt:P18 ?image ; wdt:P571 ?inception . ?creator wdt:P31 wd:Q5 ; wdt:P21 ?gender . FILTER(?gender IN (wd:Q6581072, wd:Q1052281)) } GROUP BY ?creator ?work ORDER BY ASC(?minInception) LIMIT 1000 } ?creator rdfs:label ?creatorLabel . ?work rdfs:label ?workLabel . FILTER(LANG(?creatorLabel) = "en") FILTER(LANG(?workLabel) = "en") } LIMIT 1000

Who are the earliest known female and trans women creators of artworks with images on Wikimedia Commons, and what are their works?

List the first 1000 female and trans women artists along with their earliest artworks, the associated images, and the year the works were created.

SELECT ?var1 ?var1Label ?var2 ?var2Label ?var3 ?var4 ?var5 WHERE { { SELECT ?var1 ?var2 ( SAMPLE ( ?var3 ) AS ?var3 )( MIN ( ?var4 ) AS ?var4 ) WHERE { ?var2 <http://www.wikidata.org/prop/direct/P170> ?var1 ; <http://www.wikidata.org/prop/direct/P18> ?var3 ; <http://www.wikidata.org/prop/direct/P571> ?var4 . ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . { ?var1 <http://www.wikidata.org/prop/direct/P21> <http://www.wikidata.org/entity/Q6581072> . } UNION { ?var1 <http://www.wikidata.org/prop/direct/P21> <http://www.wikidata.org/entity/Q1052281> . } } GROUP BY ?var1 ?var2 ?var5 ORDER BY ASC( ?var4 ) LIMIT 1000 } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } BIND ( CONCAT ( ?var1Label , ": ", ?var6Label ) AS ?var5 ). } LIMIT 1000


Question: Ships owned by Minoan Lines with their English Wikipedia pages and types.

SELECT ?ship ?shipLabel ?wikipediaPage ?officialWebsite ?instanceOf WHERE { ?ship wdt:P127 wd:Q1759533 . ?wikipediaPage schema:about ?ship ; schema:inLanguage "en" ; schema:isPartOf <https://en.wikipedia.org/> . OPTIONAL { ?ship wdt:P856 ?officialWebsite . } OPTIONAL { ?ship wdt:P31 ?instanceOf . } ?ship rdfs:label ?shipLabel . FILTER(LANG(?shipLabel) = "en")}

What ships are owned by Minoan Lines, and what are their English Wikipedia pages and types?

List the ships owned by Minoan Lines, along with their English Wikipedia links and classifications (e.g., ship).

SELECT ?var1 ?var1Label ?var2 ?var3 ?var4 ?var5 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P127> <http://www.wikidata.org/entity/Q1759533> . ?var2 <http://schema.org/about> ?var1 . ?var2 <http://schema.org/inLanguage> "en". ?var2 <http://schema.org/isPartOf> <https://en.wikipedia.org/> . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P856> ?var4 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P31> ?var5 . } OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P127> ?var3 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: What is the Wikidata item for the concept of computing?

PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?item ?label WHERE {
  ?item rdfs:label "computing" @en .
  FILTER(STRSTARTS(STR(?item) , "http://www.wikidata.org/entity/Q"))
}

Which entity in Wikidata has the label "computing" in English?

Find the main Wikidata entity that is labeled "computing" in English.

SELECT ?var1 ?var1Label WHERE { ?var1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#label> "computing"@en . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } }


Question: Which organizations have the Twitter handles "Epitech", "Paris2024", or "wikipedia"?

SELECT ?entity ?twitterHandle WHERE { ?entity wdt:P2002 ?twitterHandle . VALUES ?twitterHandle { "Epitech" "Paris2024" "wikipedia" } }

What entities are associated with the Twitter usernames Epitech, Paris2024, or wikipedia?

List all entities on Wikidata that use "Epitech", "Paris2024", or "wikipedia" as their Twitter handle.

SELECT ?var1 ?var2 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P2002> ?var2 . VALUES ( ?var2 ) { ( "string1" ) ( "_bengui_m" ) ( "Epitech" ) ( "string2" ) ( "string3" ) ( "string4" ) ( "string5" ) ( "SourceGoat" ) ( "phelly" ) ( "KelamWiki" ) ( "string6" ) ( "string7" ) ( "string8" ) ( "string9" ) ( "wikipedia" ) ( "string10" ) ( "string11" ) ( "string12" ) ( "string13" ) ( "string14" ) ( "TevaBde" ) ( "string15" ) ( "string16" ) ( "Paris2024" ) ( "otourly" ) ( "string17" ) ( "Wikidata" ) ( "WikiJabber" ) ( "string18" ) ( "string19" ) ( "string20" ) ( "mitooo18" ) ( "Jumijums" ) ( "Kormin_" ) } }


Question: Most depicted female historical figures in sculptures

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(COUNT(DISTINCT ?sculpture) AS ?count) WHERE {
  ?sculpture wdt:P180 ?person .
  ?sculpture wdt:P31 / wdt:P279 * wd:Q860861 .
  ?person wdt:P21 wd:Q6581072 .
  ?person wdt:P31 wd:Q5 .
  FILTER(?person != wd:Q467)
  ?person rdfs:label ?personLabel .
  FILTER(LANG(?personLabel) = "en")
}
GROUP BY ?person ?personLabel
ORDER BY DESC(?count)

Which women are depicted in the most sculptures, and how many sculptures depict each?

List female humans with the number of sculptures that depict them, sorted from most to least depicted.

SELECT ?var1 ?var1Label ?var2 ( COUNT ( DISTINCT ?var3 ) AS ?var4 ) WHERE { BIND ( "string1" AS ?var5 ). BIND ( REPLACE ( ?var5 , "$item$", STR ( ?var1 ) , "i" ) AS ?var2 ). ?var3 <http://www.wikidata.org/prop/direct/P180> ?var1 . ?var3 ( <http://www.wikidata.org/prop/direct/P31> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q860861> . ?var1 <http://www.wikidata.org/prop/direct/P21> <http://www.wikidata.org/entity/Q6581072> . ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q5> . FILTER ( ( ( ?var1 != <http://www.wikidata.org/entity/Q467> ) ) ) . SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } } GROUP BY ?var1 ?var1Label ?var2 ORDER BY DESC( ?var4 )


Question: What are all the superclass categories of processor design, including indirect ones?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT DISTINCT ?subclass WHERE {
  wd:Q1303814 wdt:P279 * ?subclass .
}

List all classes that processor design is a subclass of, directly or indirectly.

What broader concepts does CPU architecture belong to in the Wikidata taxonomy?

SELECT DISTINCT ?var1 WHERE { BIND ( <http://www.wikidata.org/entity/Q1303814> AS ?var2 ). ?var2 <http://www.wikidata.org/prop/direct/P279> * ?var1 . }


Question: What programming languages are in the same categories as Java?

SELECT ?language WHERE { wd:Q251 wdt:P31 ?type . ?language wdt:P31 ?type . ?language wdt:P31 wd:Q9143 . FILTER(?language != wd:Q251) } LIMIT 100

Can you list other programming languages that are instances of the same types as Java?

Show me programming languages similar to Java based on shared classifications.

SELECT ?var1 ?var2 WHERE { VALUES ( ?var3 ) { ( <http://www.wikidata.org/entity/Q251> ) } ?var1 <http://www.wikidata.org/prop/direct/P279> * ?var3 . OPTIONAL { ?var1 <http://www.wikidata.org/prop/direct/P279> ?var2 . } }


Question: Companies listed on stock exchanges with their exchange names.

SELECT ?company ?companyLabel ?exchange ?exchangeLabel WHERE { ?company wdt:P414 ?exchange . ?company rdfs:label ?companyLabel . ?exchange rdfs:label ?exchangeLabel . FILTER(LANG(?companyLabel) = "en") FILTER(LANG(?exchangeLabel) = "en") }

Which companies are listed on which stock exchanges, and what are their English labels?

Show me a list of companies and the stock exchanges they are traded on, including their English names.

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


Question: What is the image of the person with SNAC ARK ID w61w3c0s?

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

Show me the Wikimedia Commons image for the archival record identified by w61w3c0s.

Find the image linked to the SNAC ARK ID w61w3c0s in Wikidata.

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


Question: Most specific common class between South Korea and Argentina, and sum of distances

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 ?class ?label(2 AS ?sumDistance) WHERE {
  wd:Q884 wdt:P31 ?class .
  wd:Q414 wdt:P31 ?class .
  ?subclass wdt:P279 ?class .
  ?class rdfs:label ?label .
  FILTER(LANG(?label) = "en")
}
GROUP BY ?class ?label
ORDER BY ASC(COUNT(?subclass))
LIMIT 1

What is the most specific category that both South Korea and Argentina belong to, and what is the total number of steps from each country to this category?

Return the lowest common subclass of South Korea and Argentina along with the sum of their distances in the classification 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/Q884> ; <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/Q414> ; <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 image associated with the painting "Head of an old man." by Pietro da Cortona?

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 ?image WHERE {
  VALUES ?item {
    wd:Q22084546
  }
  ?item wdt:P18 ?image .
  ?item rdfs:label ?itemLabel .
  FILTER ( LANG( ?itemLabel ) = "en" )
}

Show me the English label and image of the painting titled "Head of an old man." from the National Museum in Warsaw.

Can you provide the image and name of the artwork "Head of an old man."?

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


Question: List automobile models and their manufacturers, sorted by manufacturer name, with manufacturer images if available.

SELECT ?automobileModel ?automobileModelLabel ?manufacturerLabel ?image WHERE { ?automobileModel wdt:P31 wd:Q3231690 ; wdt:P176 ?manufacturer . ?manufacturer rdfs:label ?manufacturerLabel . FILTER(LANG(?manufacturerLabel) = "en") ?automobileModel rdfs:label ?automobileModelLabel . FILTER(LANG(?automobileModelLabel) = "en") OPTIONAL { ?manufacturer wdt:P18 ?image . } } ORDER BY ASC(?manufacturerLabel)

What are the automobile models produced by each manufacturer, and which manufacturers have images on Wikimedia Commons?

Show me all car models with their English names and manufacturers, ordered alphabetically by manufacturer, and include any available images of the manufacturers.

SELECT ?var1 ?var1Label ?var2Label ?var3Label ?var4Label WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q3231690> ; <http://www.wikidata.org/prop/direct/P176> ?var2 . OPTIONAL { ?var2 <http://www.wikidata.org/prop/direct/P18> ?var4 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } } ORDER BY ASC( ?var2Label )


Question: List all federal law enforcement agencies in the United States.

SELECT ?agency WHERE { ?agency wdt:P31 wd:Q20858006 }

What are the federal law enforcement agencies of the United States?

Can you show me the list of U.S. federal law enforcement agencies?

SELECT DISTINCT ?var1 WHERE { BIND ( <http://www.wikidata.org/entity/Q20858006> AS ?var2 ). ?var2 <http://www.wikidata.org/prop/direct/P279> * ?var1 . }


Question: List of programming languages

SELECT ?programmingLanguage ?label WHERE { ?programmingLanguage wdt:P31 ?subclass . ?subclass wdt:P279 wd:Q9143 . ?programmingLanguage rdfs:label ?label . FILTER(LANG(?label) = "en") } LIMIT 1000

What are some examples of programming languages?

Show me a list of all known programming languages.

SELECT ?var1 WHERE { ?var1 <http://www.wikidata.org/prop/direct/P31> ?var2 . ?var2 <http://www.wikidata.org/prop/direct/P279> <http://www.wikidata.org/entity/Q9143> . } LIMIT 1000


Question: Is the Raspberry Pi 3 Model B a single-board computer according to Wikidata?

Does the Raspberry Pi 3 Model B belong to the class of single-board computers or any of its subclasses?

Is Raspberry Pi 3 Model B categorized as a single-board computer in Wikidata’s knowledge graph?

ASK WHERE { <http://www.wikidata.org/entity/Q25519213> ( <http://www.wikidata.org/prop/direct/P31> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Qnull> . <http://www.bigdata.com/queryHints#Prior> <http://www.bigdata.com/queryHints#gearing> "forwards". }


Question: Government agencies and their countries

SELECT ?agency ?agencyLabel ?country ?countryLabel WHERE { ?agency wdt:P31 wd:Q327333 . OPTIONAL { ?agency rdfs:label ?agencyLabel . FILTER(LANG(?agencyLabel) = "en") } OPTIONAL { ?agency wdt:P17 ?country . OPTIONAL { ?country rdfs:label ?countryLabel . FILTER(LANG(?countryLabel) = "en") } } }

What are the government agencies and which countries are they located in?

Show me the names of government agencies in English along with the names of their countries, if known.

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


Question: Chinese-labeled computer-related items in Wikidata with descriptions

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 ?item ?itemLabel ?itemDescription WHERE {
  ?item wdt:P31 / wdt:P279 * wd:Q68 .
  ?item rdfs:label ?itemLabel .
  ?item schema:description ?itemDescription .
  FILTER(LANG(?itemLabel) = "zh")
  FILTER(LANG(?itemDescription) = "zh")
}
LIMIT 100

What are some computers and computer-related items that have Chinese labels and descriptions?

List Chinese-named computer systems and their descriptions from Wikidata.

SELECT ?var1 ?var2Label ?var3 WHERE { <http://www.bigdata.com/queryHints#Query> <http://www.bigdata.com/queryHints#optimizer> "None". { SELECT DISTINCT ?var1 WHERE { ?var4 ?var5 <http://www.wikidata.org/entity/Q68> . ?var1 ?var6 ?var5 . ?var1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://wikiba.se/ontology#Property> . } LIMIT 100 } ?var1 <http://www.w3.org/2000/01/rdf-schema#label> ?var2Label . ?var1 <http://schema.org/description> ?var3 . FILTER ( ( ( LANG ( ?var2Label ) = "zh" ) ) ) . FILTER ( ( ( LANG ( ?var3 ) = "zh" ) ) ) . } LIMIT 100


Question: Which programming languages have influenced other programming languages, and what are the languages they influenced?

SELECT ?influencingLanguageLabel ?influencedLanguageLabel WHERE { ?influencingLanguage wdt:P31 wd:Q9143 . ?influencedLanguage wdt:P31 wd:Q9143 . ?influencedLanguage wdt:P737 ?influencingLanguage . ?influencingLanguage rdfs:label ?influencingLanguageLabel . ?influencedLanguage rdfs:label ?influencedLanguageLabel . FILTER(LANG(?influencingLanguageLabel) = "en") FILTER(LANG(?influencedLanguageLabel) = "en")}

Programming languages and their influences: list pairs where one language was inspired by another.

Show me all pairs of programming languages where the second one was influenced by the first.

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


Question: What is the most specific category that both Cincinnati and Tunis belong to?

SELECT ?commonClass (2 AS ?totalDistance) WHERE { wd:Q43196 wdt:P31 ?commonClass . wd:Q3572 wdt:P31 ?commonClass . } LIMIT 1

Which class is shared by both Cincinnati and Tunis as their most specific instance-of category?

Find the common class that both Cincinnati and Tunis are instances of, and return the total number of steps from each to that class.

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/Q43196> ; <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/Q3572> ; <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 South Korea and Africa belong to, based on their types in Wikidata?

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?commonType(?dist1 + ?dist2 AS ?totalDist) WHERE {
  {
    SELECT ?commonType(COUNT(?mid) AS ?dist1) WHERE {
      wd:Q884 wdt:P31 ?type1 .
      ?type1 wdt:P279 + ?mid .
      ?mid wdt:P279 * ?commonType .
      FILTER(?commonType != ?type1)
    }
    GROUP BY ?commonType
  }
  {
    SELECT ?commonType(COUNT(?mid) AS ?dist2) WHERE {
      wd:Q15 wdt:P31 ?type2 .
      ?type2 wdt:P279 + ?mid .
      ?mid wdt:P279 * ?commonType .
      FILTER(?commonType != ?type2)
    }
    GROUP BY ?commonType
  }
  FILTER(?commonType != wd:Q884 && ?commonType != wd:Q15)
}
ORDER BY ASC(?totalDist)
LIMIT 1

Which geographic classification encompasses both South Korea and Africa with the shortest path in the hierarchy?

Find the common superclass in Wikidata that is closest to both South Korea and Africa in terms of type inheritance depth.

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/Q884> ; <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/Q15> ; <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: How many paintings on Wikidata have a known artist and an image, compared to those missing one or both?

SELECT ?category ?count WHERE { { SELECT ?hasCreator ?hasImage (COUNT(DISTINCT ?painting) AS ?count) WHERE { ?painting wdt:P31 wd:Q3305213 . OPTIONAL { ?painting wdt:P170 ?creator . } OPTIONAL { ?painting wdt:P18 ?image . } BIND(IF(BOUND(?creator), 1, 0) AS ?hasCreator) BIND(IF(BOUND(?image), 1, 0) AS ?hasImage) } GROUP BY ?hasCreator ?hasImage ORDER BY DESC(?count) } BIND( IF(?hasCreator = 1 && ?hasImage = 1, "Has creator and image", IF(?hasCreator = 1 && ?hasImage = 0, "Has creator, no image", IF(?hasCreator = 0 && ?hasImage = 1, "No creator, has image", "No creator, no image")) ) AS ?category ) } ORDER BY DESC(?count)

What is the breakdown of paintings by whether they are attributed to an artist and whether they have an image on Wikimedia Commons?

Show me the count of paintings categorized by their creator and image availability: those with both, only a creator, only an image, or neither.

SELECT( IF ( ( ?var1 = "1"^^<http://www.w3.org/2001/XMLSchema#integer> ), IF ( ( ?var2 = "1"^^<http://www.w3.org/2001/XMLSchema#integer> ), "string1", "string2" ) , IF ( ( ?var2 = "1"^^<http://www.w3.org/2001/XMLSchema#integer> ), "string3", "string4" ) ) AS ?var3Label ) ?var4 WHERE { { SELECT ?var1 ?var2 ( COUNT ( DISTINCT ?var3 ) AS ?var4 ) WHERE { ?var3 <http://www.wikidata.org/prop/direct/P31> <http://www.wikidata.org/entity/Q3305213> . OPTIONAL { ?var3 <http://www.wikidata.org/prop/direct/P170> ?var5 . } OPTIONAL { ?var3 <http://www.wikidata.org/prop/direct/P18> ?var6 . } BIND ( IF ( BOUND ( ?var5 ) ,"1"^^<http://www.w3.org/2001/XMLSchema#integer> ,"0"^^<http://www.w3.org/2001/XMLSchema#integer> ) AS ?var1 ). BIND ( IF ( BOUND ( ?var6 ) ,"1"^^<http://www.w3.org/2001/XMLSchema#integer> ,"0"^^<http://www.w3.org/2001/XMLSchema#integer> ) AS ?var2 ). } GROUP BY ?var1 ?var2 ORDER BY DESC( ?var4 ) } } ORDER BY DESC( ?var4 )


Question: List companies and financial instruments with ticker symbols.

SELECT ?entity ?ticker WHERE { ?entity wdt:P249 ?ticker . } LIMIT 100

Which entities on Wikidata have a stock ticker symbol, and what are their tickers?

Show me up to 100 entities that are publicly traded and their corresponding ticker symbols.

SELECT ?var1 ( COUNT ( ?var1 ) AS ?var2 )( COUNT ( ?var3 ) AS ?var4 ) WHERE { SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en". } ?var1 <http://www.wikidata.org/prop/direct/P249> ?var3 . } GROUP BY ?var1 ORDER BY DESC( ?var2 ) LIMIT 100


Question: What are the top 10 most popular query languages based on Wikipedia sitelinks?

SELECT DISTINCT ?language ?languageLabel WHERE { ?language (wdt:P31|wdt:P279) wd:Q845739 . ?language rdfs:label ?languageLabel . FILTER(LANG(?languageLabel) = 'en') . OPTIONAL { ?language wdt:P1840 ?sitelinks } } ORDER BY DESC(COALESCE(?sitelinks, 0)) LIMIT 10

List the main query languages and rank them by how widely they are referenced on Wikipedia.

Which programming languages are used for querying databases, and which ones are the most prominent?

SELECT ?var1 ?var1Label WHERE { ?var1 ( <http://www.wikidata.org/prop/direct/P31> | <http://www.wikidata.org/prop/direct/P279> ) <http://www.wikidata.org/entity/Q845739> . SERVICE <http://dbpedia.org/sparql> { ?var1 ( <http://purl.org/voc/vrank#hasRank> / <http://purl.org/voc/vrank#rankValue> ) ?var2 . } SERVICE <http://wikiba.se/ontology#label> { <http://www.bigdata.com/rdf#serviceParam> <http://wikiba.se/ontology#language> "en,en". } } ORDER BY DESC( ?var2 ) LIMIT 10


Question: What are the English names of all governing bodies and their subclasses in Wikidata?

SELECT DISTINCT ?item ?itemLabel WHERE { ?item wdt:P31/wdt:P279* wd:Q895526 . FILTER NOT EXISTS { ?item rdf:type wikibase:Sense } ?item rdfs:label ?itemLabel . FILTER (LANG(?itemLabel) = "en") } LIMIT 200000

List all organizations that have authority to govern, along with their English labels.

Show me all entities classified as governing bodies or any of their subtypes, with their English names.

SELECT DISTINCT ?var1 ?var2Label WHERE { ?var1 ( <http://www.wikidata.org/prop/direct/P31> / <http://www.wikidata.org/prop/direct/P279> *) <http://www.wikidata.org/entity/Q895526> . ?var1 <http://www.w3.org/2000/01/rdf-schema#label> ?var2Label . FILTER ( ( ( LANG ( ?var2Label ) = "en" ) ) ) . } LIMIT 200000


Question: What is the image of the female breast on Wikimedia Commons?

PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
SELECT ?image WHERE {
  wd:Q9103 wdt:P18 ?image .
}

Show me the picture of the female breast from Wikidata.

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


Question: What are all the broader categories or classes that gouache painting belongs to, including indirect ones?

SELECT DISTINCT ?subclass WHERE { wd:Q21281546 wdt:P279* ?subclass . } LIMIT 100

List all the superclass types of gouache painting in the Wikidata knowledge graph.

What is the full hierarchy of categories above gouache painting, from specific to general?

SELECT DISTINCT ?var1 WHERE { BIND ( <http://www.wikidata.org/entity/Q21281546> AS ?var2 ). ?var2 <http://www.wikidata.org/prop/direct/P279> * ?var1 . }