Give me {kingdom} that {office held by head of state} {King of Joseon Dynasty} and which contains the word {joseon} in their name
Let me know the kingdom which contains the world "joseon" in its title and whose office is headed by Ruler of Joseon Line.
Tell me the kingdom which contains the world "joseon" in its name and whose office is headed by King of Joseon Dynasty.
SELECT DISTINCT ?g WHERE { FILTER ( CONTAINS ( LCASE ( ?g ) , 'joseon' ) ) . ?g rdf:type ontology:kingdom . ?g property:office_held_by_head_of_state resource:King_of_Joseon_Dynasty }
SELECT DISTINCT ?sbj ?sbj_label { ?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> ?sbj . ?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P31> . ?statement1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> <http://wikidata.dbpedia.org/resource/Q417175>. ?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> ?sbj . ?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P1906> . ?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> <http://wikidata.dbpedia.org/resource/Q22304810>. ?sbj rdfs:label ?sbj_label . FILTER(CONTAINS(lcase(?sbj_label), 'joseon')) . FILTER (lang(?sbj_label) = 'en') } LIMIT 25
SELECT DISTINCT ?sbj ?sbj_label WHERE { ?sbj wdt:P31 wd:Q417175 . ?sbj wdt:P1906 wd:Q22304810 . ?sbj rdfs:label ?sbj_label . FILTER(CONTAINS(lcase(?sbj_label), 'joseon')) . FILTER (lang(?sbj_label) = 'en') } LIMIT 25 