Question: What was the Ashgabat capital until 10-27-1924?
Paraphrase: What was the capital of Ashgabat until October 27th, 1924?
SPARQL (Wikidata): SELECT ?obj WHERE { wd:Q23438 p:P1376 ?s . ?s ps:P1376 ?obj . ?s pq:P582 ?x filter(contains(YEAR(?x),'1924')) }