Skip to content
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

Input: references #2

Open
larsgw opened this issue Dec 28, 2023 · 0 comments
Open

Input: references #2

larsgw opened this issue Dec 28, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@larsgw
Copy link
Member

larsgw commented Dec 28, 2023

As we want to restrict input, we cannot pass extra information from references along with stated in. This means missing out on reference URL, retrieved, and identifiers. The tool can instead take reference URIs as input and retrieve that information itself.

SELECT ?ref ?statedIn ?formatterUrl ?identifier ?referenceUrl ?retrieved WHERE {
  VALUES ?ref { wdref:005bca173b32a7c8f623bbeb832a152889e8f4e3 }
  OPTIONAL {
    ?ref pr:P248 ?statedIn .
    OPTIONAL {
      ?statedIn ^wdt:P9073 ?identifierProperty .
      ?identifierProperty wikibase:reference ?identifierPropertyReference .
      OPTIONAL {
        ?identifierProperty wdt:P1630 ?formatterUrl .
      }
      ?ref ?identifierPropertyReference ?identifier .
    }
  }
  OPTIONAL {
    ?ref pr:P854 ?referenceUrl .
  }
  OPTIONAL {
    ?ref pr:P813 ?retrieved .
  }
}
@larsgw larsgw added the enhancement New feature or request label Dec 28, 2023
@larsgw larsgw moved this to Todo in New Year's Eve 2023 Dec 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
No open projects
Development

No branches or pull requests

1 participant