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

Think about proposing a Wikidata property for "Maintenance query" #1134

Open
Daniel-Mietchen opened this Issue Feb 7, 2019 · 1 comment

Comments

Projects
None yet
1 participant
@Daniel-Mietchen
Copy link
Owner

Daniel-Mietchen commented Feb 7, 2019

e.g. this query can be used to curate items about earthquake-related publications:


SELECT DISTINCT ?item #?title
WHERE {
  hint:Query hint:optimizer "None".
{  SERVICE wikibase:mwapi {
    bd:serviceParam wikibase:api "Search";
                    wikibase:endpoint "www.wikidata.org";
                    mwapi:srsearch "earthquake and haswbstatement:P31=Q13442814".
    ?page_title wikibase:apiOutput mwapi:title.
  }
}
UNION
{  SERVICE wikibase:mwapi {
    bd:serviceParam wikibase:api "Search";
                    wikibase:endpoint "www.wikidata.org";
                    mwapi:srsearch "earthquake -and haswbstatement:P31=Q13442814".
    ?page_title wikibase:apiOutput mwapi:title.
  }
}
  BIND(IRI(CONCAT(STR(wd:), ?page_title)) AS ?item)
  FILTER NOT EXISTS { ?item wdt:P921 [ wdt:P31*/wdt:P279* wd:Q7944]. }
  
  ?item wdt:P31 wd:Q13442814;
        wdt:P1476 ?title.
  FILTER CONTAINS(LCASE(?title), "earthquake").
}
#LIMIT 1000

It would be good to have that represented somewhere as structured information in WIkidata, either via a dedicated property or via dedicated items.

Some relevant existing properties:

@Daniel-Mietchen

This comment has been minimized.

Copy link
Owner

Daniel-Mietchen commented Feb 7, 2019

A sample batch with the above query is at https://tools.wmflabs.org/quickstatements/#/batch/8252 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment