python (65.2k questions)
javascript (44.3k questions)
reactjs (22.7k questions)
java (20.8k questions)
c# (17.4k questions)
html (16.3k questions)
r (13.7k questions)
android (13k questions)
How to pass python variable to sparql query?
I would expect/hope something like this works:
import requests
my_variable = 'wd:Q1968435'
url = 'https://query.wikidata.org/sparql'
query = """
SELECT ?item ?itemLabel
W...
MrTree
Votes: 0
Answers: 1
How to create a SPARQL query to search Wikidata item descriptions
I'd like to be able to find an item based on words in its descriptions.
This is what I'm trying to do, but clearly I don't know what I'm doing. Any help is appreciated.
SELECT ?item ?itemLabel WHERE {...

Andrew Mayne
Votes: 0
Answers: 1
Format dates based on date precision
I am using Wikidata Query Service to get the dates of population of some places. The output gives a raw result in the format 2010-01-01T00:00:00Z (as an example). I have also retrieved the date precis...
JAT86
Votes: 0
Answers: 0
Retrieve latitude and longitude of a sample of coordinates from Wikidata using SPARQL
I am trying to retrieve samples of coordinates in Wikidata via SPARQL but am having a very difficult time trying to achieve it. I would want to get only a single pair of coordinates per place and disp...
JAT86
Votes: 0
Answers: 1