From 6af53a65584e79bf4130c317c24dab55323f11c8 Mon Sep 17 00:00:00 2001 From: RVA2869 <144518518+RVA2869@users.noreply.github.com> Date: Fri, 4 Sep 2026 20:50:15 +0200 Subject: [PATCH] Add poland --- jargon.txt | 1 + queries/countries.rq | 1 + queries/generators/poland.rq | 32 ++++++++++++++++++++++++++++++++ views.yaml | 3 +++ 4 files changed, 37 insertions(+) create mode 100644 queries/generators/poland.rq diff --git a/jargon.txt b/jargon.txt index 1a2fee84912..0d98d5666db 100644 --- a/jargon.txt +++ b/jargon.txt @@ -201,6 +201,7 @@ ph philippines platformLabel png +poland portugal pre printf diff --git a/queries/countries.rq b/queries/countries.rq index b6f534d97ac..8249bc5239c 100644 --- a/queries/countries.rq +++ b/queries/countries.rq @@ -56,6 +56,7 @@ WHERE { (wd:Q219 'Bulgaria' 'bulgaria' 'Current content includes ministries, state agencies, executive agencies, administrative structures, oblasts, municipalities, kmetstvos, municipal districts and specialized local administrations.' '') (wd:Q902 'Bangladesh' 'bangladesh' 'Current content includes ministries, ministerial divisions, divisions, districts, upazilas, embassies, permanent missions, high commissions and assistant high commissions.' '') (wd:Q1050 'Eswatini' 'eswatini' 'Current content includes ministries, agencies abroad, regions and tinkhundla' '') + (wd:Q36 'Poland' 'poland' 'Current content includes central government agencies, ministries, voivodeships, marshal\'s offices of voivodeships, voivodeship sejmiks, embassies, permanent missions and consulates generals.' '') (wd:Q145 'United Kingdom' 'united-kingdom' 'Current content includes ministerial departments.' 'Scotland|scotland') (wd:Q22 'Scotland' 'united-kingdom/scotland' 'Current content includes executive agencies, executive non-departmental public bodies, advisory non-departmental public bodies, non-ministerial offices,local authorities, NHS boards, courts, public corporations, tribunals, parole boards, King\'s printer, commissioners, ombudsmen, Health and social care partnerships and government of Scotland.' '') diff --git a/queries/generators/poland.rq b/queries/generators/poland.rq new file mode 100644 index 00000000000..f560a33618b --- /dev/null +++ b/queries/generators/poland.rq @@ -0,0 +1,32 @@ +# expected_result_count: 240 +SELECT DISTINCT + ?qid + ?orgLabel + ?orgDescription + ?type + ?typeLabel + ?country +WHERE { + BIND(wd:Q36 AS ?country) + { + VALUES ?type { + wd:Q9367288 # central government agency of Poland (34) + wd:Q6866556 # ministry of Poland (19) + wd:Q150093 # voivodeship of Poland (16) + wd:Q9367292 # marshal's office of voivodeship (16) + wd:Q675911 # voivodeship sejmik (16) + } + ?org wdt:P31 ?type . + ?org wdt:P17 ?country . + } UNION { VALUES ?type { + wd:Q2360219 # permanent mission (11) + wd:Q3917681 # embassy (95) + wd:Q372690 # consulate general (33) + } + ?org wdt:P31 ?type; wdt:P137 ?country .} + MINUS { ?org wdt:P576 [] } + MINUS { ?org wdt:P1366 pq:P582 } + BIND(REPLACE(STR(?org), "http://www.wikidata.org/entity/", "") AS ?qid) + SERVICE wikibase:label { bd:serviceParam wikibase:language "en,mul,pl" } +} +ORDER BY ?typeLabel ?orgLabel diff --git a/views.yaml b/views.yaml index 097455ed7f8..0c1444e7328 100644 --- a/views.yaml +++ b/views.yaml @@ -178,6 +178,9 @@ views: - output: "eswatini/{{qid}}/index.html" query: "generators/eswatini.rq" template: "org.html" + - output: "poland/{{qid}}/index.html" + query: "generators/poland.rq" + template: "org.html" - output: "united-kingdom/{{qid}}/index.html" query: "generators/united-kingdom.rq"