-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not an Issue : regarding documentation on using Wikidata #14
Comments
You can do that with SPARQL queries. You can play with your query on https://query.wikidata.org then use from pywikibot.data.sparql import SparqlQuery
q = SparqlQuery("SELECT ...")
for item in q:
# do something
... I don’t know if the |
Updated pywikibot syntax for the anyone googling this: from pywikibot.data.sparql import SparqlQuery
query = SparqlQuery()
for item in query.select("SELECT ..."):
# do something
... |
Hello,
Firstly this is not an issue with the code. Sorry for posting this under issues.
I wanted to get some additional documentation on using the module.
Suppose I want get a list of all the entities with a certain property.
The current documentation Wikidata client library for Python only shows how to get a property given an entity.
I'm trying to find if I can get a list of entities with the mentioned property.
e.g. get a list of countries (entities) given the property for country 'P17'.
I'm not sure if this already exists. Please let me know if it exists.
I would appreciate if the module had an improved documentation Issue #10 .
Thanks,
@sobalgi.
The text was updated successfully, but these errors were encountered: