Skip to content

Instantly share code, notes, and snippets.

@dpfoose
Created July 3, 2023 18:56
Show Gist options
  • Save dpfoose/69ed5684c80f024a07e3508051154213 to your computer and use it in GitHub Desktop.
Save dpfoose/69ed5684c80f024a07e3508051154213 to your computer and use it in GitHub Desktop.
Get All Wikidata Entries with IPEDS Unit IDs
SELECT ?item ?itemLabel ?unit_id ?openalex_id ?mag_id ?ror_id WHERE {
SERVICE wikibase:label { bd:serviceParam wikibase:language "en". }
OPTIONAL { ?item wdt:P6782 ?ror_id. }
?item wdt:P1771 ?unit_id
OPTIONAL { ?item wdt:P10283 ?openalex_id. }
OPTIONAL { ?item wdt:P6366 ?mag_id. }
}
@dpfoose
Copy link
Author

dpfoose commented Jul 3, 2023

Retrieves all entries with wdt:P1771 (IPEDS unit id) and their MAG, OpenAlex and ROR Ids
(Used to link OpenAlex with IPEDS and Carnegie Classification data).

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