what is the {statement is subject of} for {Turkey} has {diplomatic relation} as {Morocco} ?
What is the diplomatic relationship between Turkey and Morocco?
what is the statement is subject for turkey has diplomatic relation as morocco?
SELECT ?t WHERE { ?k property:diplomatic_relation resource:Morocco . ?k property:statement_is_subject_of ?t . resource:Turkey property:diplomatic_relation ?k }
select distinct ?value  where {
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#subject> <http://wikidata.dbpedia.org/resource/Q43> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#predicate> <http://www.wikidata.org/entity/P530> .
?statement <http://www.w3.org/1999/02/22-rdf-syntax-ns#object> <http://wikidata.dbpedia.org/resource/Q1028> .
?statement <http://www.wikidata.org/entity/P805> ?value. 
} 

SELECT ?value WHERE { wd:Q43 p:P530 ?s . ?s ps:P530 wd:Q1028 . ?s pq:P805 ?value}