'WikiData SPARQL query gives different numbers with and without labels
I am trying to download from Wikidata the journals with their OpenAlex id.
This query tells me that there are about 85k
SELECT (COUNT (?entity) as ?entries)
WHERE
{
?entity wdt:P31/wdt:P279? wd:Q737498.
?entity wdt:P10283 ?xopenalex_id .
}
More or less the same if I add optionally issn_l
SELECT DISTINCT (COUNT (?entity) as ?entries)
WHERE
{
?entity wdt:P31/wdt:P279? wd:Q737498.
?entity wdt:P10283 ?xopenalex_id
OPTIONAL { ?entity wdt:P7363 ?xissnl}.
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en, de,fr, ru" } .
}
But when I try to download the data I get about 20k less
both following queries return about 65k
(I wrap them in a python script using wikidataintegrator)
SELECT DISTINCT ?entity ?xopenalex_id
WHERE
{
?entity wdt:P31/wdt:P279? wd:Q737498.
?entity wdt:P10283 ?xopenalex_id
}
and this with issn_l
SELECT DISTINCT ?entity ?entityLabel ?xopenalex_id ?xissnl
WHERE
{
?entity wdt:P31/wdt:P279? wd:Q737498.
?entity wdt:P10283 ?xopenalex_id
OPTIONAL { ?entity wdt:P7363 ?xissnl}.
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en, de,fr, ru" } .
}
any idea, what I am missing ?
Thanks for any help.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
