Reputation: 2482
I set up a local instance of wikibase following this guide.
Now at http://localhost:8282 I can access a SPARQL interface which look very much like https://query.wikidata.org/ – good.
However, there seems to be no "preinstalled" data in my local instance, which is very reasonable.
To actually experiment how to add, remove and change data, I would like to copy a tiny fragment of the actual wikidata to my own instance. A particular task would be to get the cats-example to return at least some matching records.
How can I do this?
Upvotes: -2
Views: 279
Reputation: 16630
Here is a query to get RDF data:
CONSTRUCT { ?item wdt:P31 wd:Q146 ;
rdfs:label ?itemLabel ;
skos:altLabel ?itemAltLabel ;
schema:description ?itemDescription .
}
WHERE
{
?item wdt:P31 wd:Q146.
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Wikidata UI shows it as a table of triples "subject", "predicate", "object".
If you send the query to the SPARQL endpoint, you get back RDF data directly. (e.g. see question 66968955)
Upvotes: 0