Give me {major party} that {office held by head of the organisation} {chairman of the Social Democratic Party} and which contains the word {democratic} in their name
Tell me the big party that the chairman of the Social Democratic Party holds the office as head of the organization and whose name contains the word democracy?
Tell me the major party which holds the office as head of the organisation by the chairman of the Social Democratic Party and whose name contains the word democratic?
SELECT DISTINCT ?f WHERE { ?f property:office_held_by_head_of_the_organization resource:chairman_of_the_Social_Democratic_Party . ?f rdf:type ontology:major_party . FILTER ( CONTAINS ( LCASE ( ?f ) , 'democratic' ) ) }
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/Q6738353>. ?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/P2388> . ?statement2 <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> <http://wikidata.dbpedia.org/resource/Q29576752>. ?sbj rdfs:label ?sbj_label . FILTER(CONTAINS(lcase(?sbj_label), 'democratic')) . FILTER (lang(?sbj_label) = 'en') } LIMIT 25
SELECT DISTINCT ?sbj ?sbj_label WHERE { ?sbj wdt:P31 wd:Q6738353 . ?sbj wdt:P2388 wd:Q29576752 . ?sbj rdfs:label ?sbj_label . FILTER(CONTAINS(lcase(?sbj_label), 'democratic')) . FILTER (lang(?sbj_label) = 'en') } LIMIT 25 
Social Democratic Party of Germany Social Democratic Party of Germany