Thanks.

I only plan on using a query to extract from all english wikidata "articles" or all articles though anyway, hopefully the other queries will work.

On Mon, Feb 1, 2016 at 4:33 PM, Stas Malyshev <smalyshev@wikimedia.org> wrote:
Hi!

> *The first one, which seems to be only for 1 record, just as a test
> seemed to give me an ERROR though:*
>
>
> 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#>
> PREFIX schema: <http://schema.org/>
>
> SELECT *
> WHERE
> {
>    <http://www.wikidata.org/entity/Q1652291>
>  <http://schema.org/description> ?o .
>     filter(lang(?o)='en').
>
>     ?article schema:about ?item .
>     ?article schema:inLanguage "en" .
>     FILTER (SUBSTR(str(?article), 1, 25) = "https://en.wikipedia.org/")
> }

This one is not correct - ?item should be replaced by
<http://www.wikidata.org/entity/Q1652291>. Or you can use BIND or VALUES
syntax in SPARQL to bind all instanced of ?item to one or more specific
items. But if you just leave it as ?item it matches any value - which
means you just made it scan through all 15M items :) That will time out.

--
Stas Malyshev
smalyshev@wikimedia.org

_______________________________________________
Wikidata mailing list
Wikidata@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata